2100 |
Can bars have a grey backcolor and black border color for a summary-bar (EBN)
Dim hSummaryJ,hSummaryK,hSummaryN,hTaskJ,hTaskK With Exg2antt1 .BeginUpdate() With .VisualAppearance .RenderType = &Hfffffffeui .Add(1,"gBFLBCJwBAEHhEJAAEhABN0GACAADACAxRDAMgBQKAAzQFAYahuGSGAAGMYxQgmFgAQhFcZQSKUOQTDKMIziYBYJhEMQyDAAUIjOKsIhkGYcZAGQBJCjWGodQLOEgwH" & _ "IERQjEyUJAGGQIHhyPYbUbGUpQHKkeRtGqgBgoKhKEouNYgAbGYIwTRsdyfDSXBpEWwbDgkNQwWTDNoRDIUQStCysaYjOpnfrUAJ1P7FdQ1NJkXRhGSSK7maapaiCSZ6" & _ "STCMj1FhVKSNJ7DQKhGpgKh/ApgYpQOK4fLNXyRBK4QAyKA6bgPFZOZbFViaXY1V5bNKrcjhHQwAyHJ4XXRdV4YRAkUT4GqiJKGSYcQhuXZWbRqO6ABhef6DRThc6jKp" & _ "FHIE4llEcojHqSZNgoIxnlgd5thsLREleL43gsYZ9BkaAYkMAgAm+CxGDWWAtiKCRfjcdRgHoHYnicUwgAIEIREAaQYkcQZUHIGRUDQJBOEYRAhDYCxGgMZAkCgdYQha" & _ "XQIAYERwQuahXggdgeG6VZ4H4IhdiIGIOB8YIiGiHZZgqYpGF4KYHiKCI+CAU5jCiTQ2g0YhEFyax4gABAEIC") .Add(2,"gBFLBCJwBAEHhEJAAEhABU0IQAAYAQGKQYhiAKBQAGaAoDDcMA4QwAAyjAKMEwsACEIrjKCRShyCYZRhGcTAJBMIhiGQYAChEZxVhEMgzDjIAxSJAcQRFESaAABGCQG" & _ "h+N4/S4NIi0CIsZQjCaiZ7pKA5bgMCo+UrNMixZQVCSOGChYRpCaZWpGGodQRUFbVHAlKypJKCKrEWSrDhuYAAW7XM7yBS1TzVNSuLZtaLqSroAJ1WTWMB0Ra8NzZEKf" & _ "aZACj4arKejrRDCMAggI=") .Add(3,"gBFLBCJwBAEHhEJAAEhABN8GACAADACAxRDgMQBQKAAzQFAcDBvBgABiHEZoJhUAIIRZGMIjFDcEwxDSMY7jcYAFgkNQwCUtcBIJDEMIoAJLIwyBKkNQ5AabYrmWJpM" & _ "gOEAyDSJM70DCEThLD4aZJnOa5ZjmH5LRBQdBRXQMYwIGCiZQpeKqbgMBoJApCIJxdBNLAAf60LLtGJaSpKZouViJNjSBD4HQTL6BQwsKxIDqaaD/WpgFuLTjiRImShc" & _ "MQXJYFbwTOyBbDjG7rJr+FptYRbdYYRQ8dy7Cywa6pOa8YwacotZrAdDXHTmHw1PTRNDmTRYRwfKqJZxieqwHoMLYgAC8Ni3OaoDAiCRQGiYZyHKaRSwPBInIYIIjeRg" & _ "zBSAYKCEOySEodZbjybo0HefwfhMLQDnKeg9D6LwsCeV5unYQJYH8Lxvj+a5jgSfIYH8T43hOcZ5H+X4nh2fB6F+aABnOAIfFgFgGgGH43nICoCl+eA1n0fBhAgVZ5gS" & _ "HoID4FoDCCCBqBuBYUjgfgigGURYg4JoJmKCBFBaChikiNgVEYYpokYMoMCMKJWCkcIjgiZg6E0Do3gUASAg=") End With .Columns.Add("Task") With .Chart .set_PaneWidth(False,128) .FirstVisibleDate = #1/1/2001# With .Bars.Item("Task") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) .Color32 = &H1000000 End With With .Bars.Item("Summary") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) .Color32 = &H2000000 End With With .Bars.Copy("Summary","SummaryN") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) .Color32 = &H3000000 End With End With With .Items hSummaryJ = .AddItem("Summary A") .AddBar(hSummaryJ,"Summary",#1/2/2001#,#1/2/2001#,"J") hTaskJ = .InsertItem(hSummaryJ,Nothing,"Task A.1") .AddBar(hTaskJ,"Task",#1/2/2001#,#1/5/2001#,"J1") hTaskJ = .InsertItem(hSummaryJ,Nothing,"Task A.2") .AddBar(hTaskJ,"Task",#1/4/2001#,#1/8/2001#,"J2") .DefineSummaryBars(hSummaryJ,"J",-1,"<*>") hSummaryK = .AddItem("Summary B") .AddBar(hSummaryK,"Summary",#1/2/2001#,#1/2/2001#,"K") hTaskK = .InsertItem(hSummaryK,Nothing,"Task B.1") .AddBar(hTaskK,"Task",#1/2/2001#,#1/5/2001#,"K1") hTaskK = .InsertItem(hSummaryK,Nothing,"Task B.2") .AddBar(hTaskK,"Task",#1/4/2001#,#1/8/2001#,"K2") .DefineSummaryBars(hSummaryK,"K",-1,"<*>") hSummaryN = .AddItem("Summary C") .AddBar(hSummaryN,"SummaryN",#1/2/2001#,#1/2/2001#,"SN") hTaskK = .InsertItem(hSummaryN,Nothing,"Task B.1") .AddBar(hTaskK,"Task",#1/2/2001#,#1/5/2001#,"N1") hTaskK = .InsertItem(hSummaryN,Nothing,"Task B.2") .AddBar(hTaskK,"Task",#1/4/2001#,#1/8/2001#,"N2") .DefineSummaryBars(hSummaryN,"SN",-1,"<*>") .set_ItemBar(0,"<K*>",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarColor,255) .set_ItemBar(0,"<N*>",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarColor,8421504) .set_ExpandItem(0,True) End With .EndUpdate() End With |
2099 |
How can I display UNICODE characters
With Exg2antt1 .BeginUpdate() .Chart.set_PaneWidth(True,0) With .Font .Name = "Arial Unicode" .Size = 22 End With .HeaderVisible = exontrol.EXG2ANTTLib.HeaderVisibleEnum.exHeaderHidden .DefaultItemHeight = 48 .Columns.Add("").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueFormat,1) With .Items .AddItem("Ӓӓ") .AddItem("ᦜᦝ;ᦞ") .AddItem("ɮɭ;ɯ") .AddItem("勳勴勵勶") .set_FormatCell(.AddItem(Exg2antt1.Version),0,"(value lfind `UNICODE`) < 0 ? `<fgcolor=FF0000><b>!UNICODE!</b> version</fgcolor> required: ` + value : `` ") End With .EndUpdate() End With |
2098 |
How can I display 12-hour time (method 2)
With Exg2antt1 .BeginUpdate() With .Chart .FirstVisibleDate = #1/1/2001# .set_PaneWidth(False,0) .LevelCount = 2 .get_Level(0).Label = 4096 With .get_Level(1) .Unit = exontrol.EXG2ANTTLib.UnitEnum.exHour .FormatLabel = "(0 := hour(dvalue)) < 12 ? ( `<fgcolor=808080>` + ( =:0 = 0 ? 12 : =:0 ) + `</fgcolor>` ) : (=:0 - 12)" End With End With .EndUpdate() End With |
2097 |
How can I display 12-hour time (method 1)
With Exg2antt1 .BeginUpdate() With .Chart .FirstVisibleDate = #1/1/2001# .set_PaneWidth(False,0) .LevelCount = 2 .get_Level(0).Label = 4096 .get_Level(1).Label = "<%h12%>" End With .EndUpdate() End With |
2096 |
How do I scale to hours
With Exg2antt1 .BeginUpdate() With .Chart .FirstVisibleDate = #1/1/2001# .set_PaneWidth(False,0) .LevelCount = 2 .get_Level(0).Label = 4096 .get_Level(1).Label = 65536 End With .EndUpdate() End With |
2095 |
How do I display the position of the item with 0-padding
With Exg2antt1 .BeginUpdate() .Columns.Add("Items").FormatColumn = "((1 apos ``) lpad `00`) + `. ` + value" With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") .AddItem("Item D") End With .EndUpdate() End With |
2094 |
Can I format the label in row 3 below to show day numbers, only for Mondays each week (sample 2)
With Exg2antt1 With .Chart .set_PaneWidth(False,0) .FirstVisibleDate = #1/31/2009# .LevelCount = 3 .FirstWeekDay = exontrol.EXG2ANTTLib.WeekDayEnum.exMonday With .get_Level(0) .Label = "<%mmmm%> <%yyyy%>" .Alignment = exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment .Unit = exontrol.EXG2ANTTLib.UnitEnum.exMonth End With With .get_Level(1) .Unit = exontrol.EXG2ANTTLib.UnitEnum.exWeek .Label = "Week <%ww%>" .Alignment = exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment End With With .get_Level(2) .Unit = exontrol.EXG2ANTTLib.UnitEnum.exDay .FormatLabel = "weekday(dvalue) = 1 ? day(dvalue): ''" End With .UnitWidth = 23 End With End With |
2093 |
Can I format the label in row 3 below to show day numbers, only for Mondays each week (sample 1)
With Exg2antt1 With .Chart .set_PaneWidth(False,0) .FirstVisibleDate = #1/31/2009# .LevelCount = 3 .FirstWeekDay = exontrol.EXG2ANTTLib.WeekDayEnum.exMonday With .get_Level(0) .Label = "<%mmmm%> <%yyyy%>" .Alignment = exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment .Unit = exontrol.EXG2ANTTLib.UnitEnum.exMonth End With With .get_Level(1) .Unit = exontrol.EXG2ANTTLib.UnitEnum.exWeek .Label = "Week <%ww%>" .Alignment = exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment End With With .get_Level(2) .Unit = exontrol.EXG2ANTTLib.UnitEnum.exDay .FormatLabel = "weekday(dvalue) = 1 ? value : ''" End With .UnitWidth = 23 End With End With |
2092 |
How can I change the caption for all bars
With Exg2antt1 .BeginUpdate() .Columns.Add("Tasks") With .Chart .FirstVisibleDate = #8/1/2017# .LevelCount = 2 .set_PaneWidth(False,128) With .Bars.Add("Task%Progress") .Shortcut = "Task" .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarShowPercentCaption,True) End With End With With .Items .AddBar(.AddItem("Task 1"),"Task",#8/2/2017#,#8/6/2017#) .AddBar(.AddItem("Task 2"),"Task",#8/3/2017#,#8/9/2017#) .AddBar(.AddItem("Task 3"),"Task",#8/4/2017#,#8/13/2017#) .AddBar(.AddItem("Task 4"),"Task",#8/5/2017#,#8/16/2017#) .set_ItemBar(0,"<*>",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarShowPercentCaption,False) .set_ItemBar(0,"<*>",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%= %C0 replace `Task` with `Task<off 4><b>` %>") .set_ItemBar(0,"<*>",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With .EndUpdate() End With |
2091 |
Can't get the +/- to be displayed on a divider item. What else can I do
Dim h With Exg2antt1 .BeginUpdate() .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines .TreeColumnIndex = 0 .MarkSearchColumn = False .FullRowSelect = exontrol.EXG2ANTTLib.CellSelectEnum.exColumnSel .HeaderAppearance = &Hfffffff8 Or exontrol.EXG2ANTTLib.AppearanceEnum.Bump Or exontrol.EXG2ANTTLib.AppearanceEnum.Sunken .Chart.set_PaneWidth(True,0) With .Columns .Add("C1").Width = 32 .Add("C2").FormatColumn = "1 index ``" End With With .Items h = .AddItem("Cell 1") .set_CellSingleLine(h,1,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) h = .AddItem("This is bit of text merges all cells in the item (divider shows no +/-)") .set_ItemDivider(h,0) .set_ItemBackColor(h,Color.FromArgb(240,240,240)) .set_ItemDividerLine(h,exontrol.EXG2ANTTLib.DividerLineEnum.EmptyLine) .set_CellHAlignment(h,0,exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment) .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") .set_ExpandItem(h,True) h = .AddItem("Cell 3") h = .AddItem("This is bit of text merges all cells in the item (merge shows +/-)") .set_ItemBackColor(h,Color.FromArgb(240,240,240)) .set_CellMerge(h,0,1) .InsertItem(h,Nothing,"Child 3") .InsertItem(h,Nothing,"Child 4") .set_ExpandItem(h,True) End With .EndUpdate() End With |
2090 |
How can I display one or more columns on the same bar
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem Dim l With Exg2antt1 With .Items .set_ItemDividerLine(Item,exontrol.EXG2ANTTLib.DividerLineEnum.EmptyLine) .AddBar(Item,"Summary",#12/2/2017#,#12/2/2017#) .DefineSummaryBars(Item,"",-3,"") l = .get_GroupItem(Item) .set_CellSingleLine(Item,l,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) .set_CellBold(Item,l,True) .set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With .Chart.set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/10/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() .VisualAppearance.Add(1,"gBFLBCJwBAEHhEJAAEhABOUGACAADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJwFgmEgADCMQwAFBIbhrE4ZBjHGQRUgyI43RhHUBzV" & _ "IUBxDEaTZLlEYJBgeHYhDJPcaUVDcWQHGyeZwjSgpKoWSJIU5NcggPDgEwTKCmKlTAKoSzJMyEmwWRAdVTZLSEaxierKPhyWT/XgAF4PfDFKRXFqXY5mKZJFqKOI8TxI" & _ "NgxPQMGyrBqraLqKwQGrGCQKSBhUZ3dS2JR3OSlYRuQAMVgOXoDZhPWZXbDtSzPE63NgtOR5DiGWalABoeoxRa9cz3ViCJSrGTqIoINIzZLHFQbPpdAYdP6BeIjXhhZx" & _ "BBuLZXmEOh9CcNoni2N4MjWVodh+DpfBeLJinsWR9AyYwVAkGBhEAFphGiRogDEGBamkFgtjcZgHiMbgehYaQhAIEIREAaQYkcQZUHIGRUGQDBOEaBAhDYDxGkMZAkCg" & _ "eoagYZAYEYAYIAWGhemICIFj8WIiCiFR5gkIhogmBoKGKJx2C6C5hniMgggqYwog0UoNGMZJiDiCZRgOLY0ECUAQICA==") With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) With .Bars.Item("Summary") .StartShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .EndShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .Shape = exontrol.EXG2ANTTLib.ShapeBarEnum.exShapeSolid .Color32 = &H1000000 .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%513%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With With .Bars.Item("Task") .Pattern = exontrol.EXG2ANTTLib.PatternEnum.exPatternBox .Color = Color.FromArgb(164,164,164) .StartColor = Color.FromArgb(240,240,240) .EndColor = .StartColor .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%= `<font ;6><fgcolor=0000FF><i>` + %C0 + ` ` + %C1 + ` ` + %C2 %>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,13) End With End With With .Columns .Add("C1") .Add("C2").Editor.EditType = exontrol.EXG2ANTTLib.EditTypeEnum.EditType .Add("C3").Editor.EditType = exontrol.EXG2ANTTLib.EditTypeEnum.EditType With .Add("Pos") .FormatColumn = "1 pos ``" .AllowGroupBy = False .Position = 0 .Width = 48 .AllowSizing = False End With End With .SortBarVisible = True .SortBarCaption = "Drag a <b>column</b> header here to group by that column." .AllowGroupBy = True .HasLines = exontrol.EXG2ANTTLib.HierarchyLineEnum.exNoLine .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exNoLinesAtRoot With .Items h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.3") .set_CellValue(h,2,"SubItem A.4") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.5") .set_CellValue(h,2,"SubItem A.6") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.7") .set_CellValue(h,2,"SubItem A.8") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.3") .set_CellValue(h,2,"SubItem B.4") End With With .Columns.Item(0) .SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending End With .EndUpdate() End With |
2089 |
How can I associate a box/note to a date into the control's header
Dim hLocked With Exg2antt1 .BeginUpdate() .ScrollBySingleLine = True .Columns.Add("Task") .HeaderHeight = 17 With .Chart .FirstVisibleDate = #1/1/2001# .set_PaneWidth(False,96) .LevelCount = 2 .SelBackColor = Exg2antt1.SelBackColor End With With .Items .AddItem("Item 1") .set_SelectItem(.AddItem("Item 2"),True) .AddItem("Item 3") End With With .Chart.Notes With Exg2antt1.Items .set_LockedItemCount(exontrol.EXG2ANTTLib.VAlignmentEnum.exTop,1) hLocked = .get_LockedItem(exontrol.EXG2ANTTLib.VAlignmentEnum.exTop,0) .set_ItemHeight(hLocked,1) End With With .Add("header",hLocked,#1/7/2001#,"Date:<br><%dd%>/<%mm%><br><b><%yyyy%></b>") .set_PartVisible(exontrol.EXG2ANTTLib.NotePartEnum.exNoteStart,True) .set_PartText(exontrol.EXG2ANTTLib.NotePartEnum.exNoteStart,"<b><%d%></b>") .set_PartCanMove(exontrol.EXG2ANTTLib.NotePartEnum.exNoteEnd,True) .set_PartCanMove(exontrol.EXG2ANTTLib.NotePartEnum.exNoteStart,True) .set_PartVOffset(exontrol.EXG2ANTTLib.NotePartEnum.exNoteStart,-9) .set_PartVOffset(exontrol.EXG2ANTTLib.NotePartEnum.exNoteEnd,20) .set_PartHOffset(exontrol.EXG2ANTTLib.NotePartEnum.exNoteEnd,20) .set_PartBackColor(exontrol.EXG2ANTTLib.NotePartEnum.exNoteStart,Color.FromArgb(255,255,0)) .set_PartFixedWidth(exontrol.EXG2ANTTLib.NotePartEnum.exNoteStart,18) End With End With .EndUpdate() End With |
2088 |
How can I define a column of button type
' ButtonClick event - Occurs when user clicks on the cell's button. Private Sub Exg2antt1_ButtonClick(ByVal sender As System.Object,ByVal Item As Integer,ByVal ColIndex As Integer,ByVal Key As Object) Handles Exg2antt1.ButtonClick With Exg2antt1 With .Items Debug.Print( .get_CellValue(Item,ColIndex) ) End With End With End Sub With Exg2antt1 .BeginUpdate() With .Columns.Add("Button") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellHasButton,True) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellButtonAutoWidth,False) .FormatColumn = "``" .AllowSizing = False .Width = 48 End With .Columns.Add("Second").FormatColumn = "` Item ` + 1 index ``" With .Items .AddItem("Button 1") .AddItem("Button 2") .AddItem("Button 3 ") End With .EndUpdate() End With |
2087 |
Is it possible to configure different colour/icon when there is a active filter
' FilterChange event - Occurs when the filter was changed. Private Sub Exg2antt1_FilterChange(ByVal sender As System.Object) Handles Exg2antt1.FilterChange With Exg2antt1 .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exHeaderFilterBarButton,.FormatABC("value = 0 ? 0x1000001 : 0x10000FF ",.Columns.Item(0).FilterType)) End With End Sub With Exg2antt1 .BeginUpdate() With .VisualAppearance .RenderType = &Hff000000ui .Add(1,"gBFLBCJwBAEHhEJAAEhABXUIQAAYAQGKIcBiAKBQAGYBIJDEMgzDDAUBjKKocQTC4AIQjCK4JDKHYJRpHEZyCA8EhqGASRAFUQBYiWE4oSpLABQaK0ZwIGyRIrkGQgQ" & _ "gmPYDSDNU4zVIEEglBI0TDNczhNDENgtGYaJqHIYpZBcM40TKkEZoSIITZcRrOEBiRL1S0RBhGcRUHZlWzdN64LhuK47UrWdD/XhdVzXRbjfz1Oq+bxve48Br7A5yYTh" & _ "dr4LhOFQ3RjIL4xbIcUwGe6VZhjOLZXjmO49T69HTtOCYBEBA") End With .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines .ShowFocusRect = False .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exHeaderFilterBarButton,&H1000001) .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exCursorHoverColumn,-1) .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched .BackColorHeader = Color.FromArgb(255,255,255) .HeaderVisible = exontrol.EXG2ANTTLib.HeaderVisibleEnum.exHeaderVisibleExtendLevels With .Columns.Add("Filter") .DisplayFilterButton = True .AllowSort = False .AllowDragging = False .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With With .Columns.Item(0) .Filter = "Item B" .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter End With .ApplyFilter() .EndUpdate() End With |
2086 |
ADODB Requery sample
' ButtonClick event - Occurs when user clicks on the cell's button. Private Sub Exg2antt1_ButtonClick(ByVal sender As System.Object,ByVal Item As Integer,ByVal ColIndex As Integer,ByVal Key As Object) Handles Exg2antt1.ButtonClick Dim cmd With Exg2antt1 cmd = New ADODB.Command() With cmd .ActiveConnection = Exg2antt1.DataSource.ActiveConnection .CommandText = "INSERT INTO Orders (EmployeeID) VALUES(12345)" .CommandType = 1 .Execute() End With .DataSource.Requery() End With End Sub ' Error event - Fired when an internal error occurs. Private Sub Exg2antt1_Error(ByVal sender As System.Object,ByVal Err As Integer,ByVal Description As String) Handles Exg2antt1.Error With Exg2antt1 Debug.Print( Description ) End With End Sub Dim h,rs With Exg2antt1 .BeginUpdate() .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched .ColumnAutoResize = False rs = New ADODB.Recordset() With rs .Open("Select * From Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb",1,3) End With .DataSource = rs .ConditionalFormats.Add("%1=12345").BackColor = Color.FromArgb(240,240,240) With .Items .set_LockedItemCount(exontrol.EXG2ANTTLib.VAlignmentEnum.exTop,1) h = .get_LockedItem(exontrol.EXG2ANTTLib.VAlignmentEnum.exTop,0) .set_ItemDivider(h,0) .set_CellHasButton(h,0,True) .set_CellValue(h,0,"Requery (add a new record, using ADODB.Command)") .set_CellHAlignment(h,0,exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment) End With .EndUpdate() End With |
2085 |
I am skinning the control's header-bar, but the background of the header-bar is shown on each item in the filter-bar drop down panel. What can I do
With Exg2antt1 .BeginUpdate() With .VisualAppearance .Add(1,"gBFLBCJwBAEHhEJAAEhABFgDg6AADACAxRDgMQBQKAAzQFAYcBqGqGAAGQZxYgmFgAQhFcZQSKUOQTDKMIziYBYfgkMIgSbJUgDGAkRRdDSOYDmGQYDiCIoRShOMIjH" & _ "LUXxtDaIZwhEAoJb+RgAUY/cTzaAEUwHHiTKInaCQGhsCYJUJAdRURQ9EwvCIZBpEWwLChENQwWLCNj2TScBwjCyqbale45ViqdoDU8lORLUi+M4zSBPcZVTRtGShPDB" & _ "KTjMKKYgkG4lVpRNa0PC1GTzQ6mazkKQLRADDIDVbAeL3LiMBy9LyLLItQALByua5mWhbcZyBCOPgBTrRb5zO58FjuTK7YLjMB7NrUNYtFaUMy2OpOCADIaecTNcaWLx" & _ "PF2MY1HWYxVj2Jw3DuRJonKYBgggSRAlIYw6B0ThGFgPAkFUDAhBMfZRiGNAkFECZnm4YQdneJwqnsSQrGAAhWAIJBJBIQgFCQIBiEIAglgqYo0i4V4MEgRI9gSToYFS" & _ "b4Fk6Y4+BmBZhFOJgTC8TBogQAArgqco4muCZOkOMJtgmYpIjYKg7GKE4uCUK4AAKKg2DwI4DiCZw5k6KJ2D6D4OHiag4DwIxiiQAArAqMosnEPBPAOIhOg+DozjIJ4P" & _ "GSY4iEwPAkhKLhHUUSQsnKFCnkYU9MjORhcCsAAIACLQ8iaSJ6FKC5jJoaobA8KYoACCRKnmMJzhuDpZnSboMCKGJ4nMPIPDmYAACwKIDk6CoLCeU40m6I5oliMoKDya" & _ "ICokLIpgoThviOKJoGYf4KmUKhMjMLJLCAAojCyaYoiYGoGmqM46CkOwPEoKonAACxKlSdItmiWBeBeDgrioNo3D0KxSlAAAtgsUpYnUPRPEoco8hCa+T40SxbBRj5tE" & _ "sHJ1i6JhbGYS4ug8awelQLZAAKZI5C4DxrhYQ9ehmUppWiA48nAPRuFKYpiAAC47laZQ9iuKZSgOPotkuFI7C6C4gACPJAm8eQOhOQZoikDp3kCS5AACPoEk8fBGnqQg" & _ "pDOSppD2TxjlyPZD6CfwekQTx5lKP5ImseZTCAL5MAMAAAkoTADmMLpIjISp+HSS4PgyMAADBzAHDSIoPCOUpWjObIKE8NJOHKIwPEaTprBsHpdjWLB9AieQ+DQYwQAA" & _ "MR1EOZxWi+bx7HcWQ8msfRYnnDhQACRwxgwc5rGaMZPE0ZxqjWNZtgyRwAAyTZEnuXJzEyAx2kQcxNkye5cEy3cYAcANrGAIH4OAhx3gNGGPAfgIR8jBA4McBMARViHH" & _ "4HQOYmxuCpF2MsecEQVBvGQCcIQvA6i2CAAIARAQ=") .Add(2,"gBFLBCJwBAEHhEJAAEhABZEGACAADACAxRDgMQBQKAAzQFAYcBqGqGAAGQZxYgmFgAQhFcZQSKUOQTDKMIziYBYJhEMwwDhEIwjHCEEhsGIbJAGQBJCjWGodQLOEgzN" & _ "C0IxNFCQILhEZJADKII8TTOU5UPRESwTE4cKBmKhQCo2NpKR7VUTxCKQahLLivoCjBT8EzHMqtIzrCA6MpaP4pQjKcqwHJ8YyHEi0ZrjazKaj6T5AXDUcaWbbNVx3PK3" & _ "aioOpLZrqOZZYzYFoABTuJzPMSyIhxXD8cweaZvSpLExVYK9BY3PbKMgxC77QgTIpDaQMNS6PjtF43PAALLFUaNYzoOKzABMHATBIXAYJCwIIR5G7ID4BbQcCQAHL9DB" & _ "aEEIAEEISgGhMGZQmocgymmIRQkIEQ2BcGgbEIRQci8XaMBqTRVgSAZHG+S5pnOep+D6f4vjec5zn0fpfmgBgAH6TRoBYBoAh+eAmAiAgPFgNArgOQpIESdoEmCOAOAq" & _ "BYfFGAgaEaBgYHYFYFmIB5UiGCJUgKCgmgeYoHk4BgCmKRQiCwApgHgYgyH8B54lQU4NkMeJlBoDgjkiXBTg0R54iYIR+koeQVBoKpkgkChKhEJBkF4SFEjkDgJhFQoe" & _ "EmDJlBeehUhWJQJGIXoICWOQ6FeFIlhkfhlDsSJpiQVoamaSY2G6G5nAmRhpCOH5pkwVYdmeCZmHqHpnkmdhzhmaAIFiax8AABAEICA==") End With .BackColorHeader32 = &H1000000 .ForeColorHeader = Color.FromArgb(128,128,128) .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exHeaderFilterBarButton,&H2000000) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exBackColorFilter,Color.FromArgb(255,255,255)) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exForeColorFilter,Color.FromArgb(0,0,1)) .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exSelBackColorFilter,&H1ff8000) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exSelForeColorFilter,Color.FromArgb(240,240,240)) .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exCursorHoverColumn,-1) .HeaderHeight = 24 .BackColorLevelHeader = .BackColor With .Columns.Add("Filter") .DisplayFilterButton = True .DisplayFilterPattern = False .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exHeaderPaddingLeft,2) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exHeaderPaddingRight,2) End With With .Items .AddItem("A") .AddItem("B") .AddItem("C") .AddItem("D") End With .EndUpdate() End With |
2084 |
I specify the ItemHeight for each row, but as soon as I click the chart section, the item's height is restored to default (not working). What could be the cause
Dim h With Exg2antt1 .BeginUpdate() .ScrollBySingleLine = True .Columns.Add("Types") .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exHLines With .Chart .LevelCount = 2 .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exHLines .AllowCreateBar = exontrol.EXG2ANTTLib.CreateBarEnum.exCreateBarAuto .AllowLinkBars = False .ResizeUnitScale = exontrol.EXG2ANTTLib.UnitEnum.exHour .set_PaneWidth(False,112) .FirstVisibleDate = #1/1/2001# With .Bars.Item("Task") .OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStack .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%9%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With End With With .Items h = .AddItem("ItemMinHeight") .AddBar(h,"Task",#1/7/2001#,#1/10/2001#,"A1") .AddBar(h,"Task",#1/8/2001#,#1/12/2001#,"A2") .set_ItemMinHeight(h,64) .AddBar(.AddItem("Default (One)"),"Task",#1/7/2001#,#1/10/2001#,"A3") h = .AddItem("Default (Two)") .AddBar(h,"Task",#1/7/2001#,#1/10/2001#,"A4") .AddBar(h,"Task",#1/8/2001#,#1/12/2001#,"A5") h = .AddItem("ItemFixedHeight") .AddBar(h,"Task",#1/7/2001#,#1/10/2001#,"A6") .AddBar(h,"Task",#1/8/2001#,#1/12/2001#,"A7") .set_ItemMinHeight(h,20) .set_ItemMaxHeight(h,20) h = .AddItem("ItemMaxHeight") .AddBar(h,"Task",#1/7/2001#,#1/10/2001#,"A8") .AddBar(h,"Task",#1/8/2001#,#1/12/2001#,"A9") .set_ItemMaxHeight(h,24) End With .EndUpdate() End With |
2083 |
The ItemHeight property is not working (method 2)
Dim h With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False .ScrollBySingleLine = True .Columns.Add("Column").Width = 128 With .Items .set_CellSingleLine(.AddItem("This is a bit of text that should break the line"),0,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) h = .AddItem("") .set_ItemDivider(h,0) .set_SelectableItem(h,False) .set_ItemDividerLineAlignment(h,exontrol.EXG2ANTTLib.DividerAlignmentEnum.DividerCenter) .set_ItemHeight(h,3) .set_CellSingleLine(.AddItem("This is a bit of text that should break the line"),0,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) End With .EndUpdate() End With |
2082 |
The ItemHeight property is not working (method 1)
Dim h With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False .ScrollBySingleLine = True With .Columns.Add("Column") .Width = 128 .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellSingleLine,0) End With With .Items .AddItem("This is a bit of text that should break the line") h = .AddItem("") .set_ItemDivider(h,0) .set_SelectableItem(h,False) .set_ItemDividerLineAlignment(h,exontrol.EXG2ANTTLib.DividerAlignmentEnum.DividerCenter) .set_ItemMinHeight(h,3) .set_ItemMaxHeight(h,3) .AddItem("This is a bit of text that should break the line") End With .EndUpdate() End With |
2081 |
How do I use the ColumnsFloatBarVisible on exColumnsFloatBarVisibleIncludeCheckColumns
With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched With .Columns .Add("City") .Add("Start").Visible = False .Add("End").Visible = False End With .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exColumnsFloatBar,"Show/Hide") .ColumnsFloatBarSortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .ColumnsFloatBarVisible = exontrol.EXG2ANTTLib.ColumnsFloatBarVisibleEnum.exColumnsFloatBarVisibleIncludeCheckColumns .EndUpdate() End With |
2080 |
How do I use the ColumnsFloatBarVisible on exColumnsFloatBarVisibleIncludeHiddenColumn
With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched With .Columns .Add("City") .Add("Start").Visible = False .Add("End").Visible = False End With .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exColumnsFloatBar,"Show") .ColumnsFloatBarVisible = exontrol.EXG2ANTTLib.ColumnsFloatBarVisibleEnum.exColumnsFloatBarVisibleIncludeHiddenColumns .ColumnsFloatBarSortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .EndUpdate() End With |
2079 |
How do I use the ColumnsFloatBarVisible on exColumnsFloatBarVisibleIncludeGroupByColumns
With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched With .Columns .Add("City") .Add("Start") .Add("End") End With .AllowGroupBy = True .SortBarVisible = True .SortBarCaption = "Drag a <b>column</b> header here to group by that column." .BackColorSortBar = Color.FromArgb(250,250,250) .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exColumnsFloatBar,"Group-By") .ColumnsFloatBarVisible = exontrol.EXG2ANTTLib.ColumnsFloatBarVisibleEnum.exColumnsFloatBarVisibleIncludeGroupByColumns .ColumnsFloatBarSortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .Columns.Item("City").SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .EndUpdate() End With |
2078 |
How can I advance to the next line, once the user presses the ENTER key
' KeyDown event - Occurs when the user presses a key while an object has the focus. Private Sub Exg2antt1_KeyDown(ByVal sender As System.Object,ByRef KeyCode As Short,ByVal Shift As Short) Handles Exg2antt1.KeyDown With Exg2antt1 Debug.Print( "KeyCode Before:" ) Debug.Print( KeyCode ) KeyCode = .FormatABC("value = 13 ? 40 : value",KeyCode) Debug.Print( "KeyCode After:" ) Debug.Print( KeyCode ) End With End Sub Dim h0 With Exg2antt1 .BeginUpdate() With .Columns With .Add("A").Editor .Appearance = exontrol.EXG2ANTTLib.InplaceAppearanceEnum.EtchedApp .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.EditType End With With .Add("B").Editor .Appearance = exontrol.EXG2ANTTLib.InplaceAppearanceEnum.EtchedApp .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.EditType End With End With With .Items h0 = .AddItem("Item A.1") .set_CellValue(h0,1,"Item B.1") h0 = .AddItem("Item A.2") .set_CellValue(h0,1,"Item B.2") End With .EndUpdate() End With |
2077 |
I am using AddNew to add new records, but I can not see them into the control
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,1),.get_CellValue(Item,2)) End With End With End Sub ' ButtonClick event - Occurs when user clicks on the cell's button. Private Sub Exg2antt1_ButtonClick(ByVal sender As System.Object,ByVal Item As Integer,ByVal ColIndex As Integer,ByVal Key As Object) Handles Exg2antt1.ButtonClick With Exg2antt1 With .DataSource .AddNew() .Fields.Item("Name").Value = "Task New" .Update() End With End With End Sub Dim h,rs With Exg2antt1 .BeginUpdate() .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched rs = New ADODB.Recordset() With rs With .Fields .Append("Name",8) .Append("Start",7) .Append("End",7) End With .Open() .AddNew() .Fields.Item("Name").Value = "Task A" .Fields.Item("Start").Value = #1/4/2001# .Fields.Item("End").Value = #1/10/2001# .Update() .AddNew() .Fields.Item("Name").Value = "Task B" .Fields.Item("Start").Value = #1/5/2001# .Fields.Item("End").Value = #1/11/2001# .Update() End With .DataSource = rs With .Chart .FirstVisibleDate = #1/1/2001# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item("Start").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item("End").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) With .Items .set_LockedItemCount(exontrol.EXG2ANTTLib.VAlignmentEnum.exTop,1) h = .get_LockedItem(exontrol.EXG2ANTTLib.VAlignmentEnum.exTop,0) .set_ItemDivider(h,0) .set_CellHasButton(h,0,True) .set_CellValue(h,0,"AddNew") .set_CellHAlignment(h,0,exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment) End With .DetectAddNew = True .DetectDelete = True .EndUpdate() End With |
2076 |
How can I create a new ADO recordset
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,1),.get_CellValue(Item,2)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() rs = New ADODB.Recordset() With rs With .Fields .Append("Name",8) .Append("Start",7) .Append("End",7) End With .Open() .AddNew() .Fields = "Task A" .Fields = #1/4/2001# .Fields = #1/10/2001# .Update() .AddNew() .Fields = "Task B" .Fields = #1/5/2001# .Fields = #1/11/2001# .Update() End With .DataSource = rs With .Chart .FirstVisibleDate = #1/1/2001# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item("Start").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item("End").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2075 |
Do do I get the DAO version I have installed
With Exg2antt1 Debug.Print( New DAO.PrivDBEngine().Version ) Debug.Print( New DAO.PrivDBEngine().Version ) Debug.Print( New DAO.PrivDBEngine().Version ) End With |
2074 |
How do I get a list of interfaces the object implemenets
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,2),.get_CellValue(Item,4)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False With New DAO.PrivDBEngine() rs = .OpenDatabase("C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb").OpenRecordset("Orders") End With Debug.Print( New Object() ) .DataSource = rs With .Chart .FirstVisibleDate = #8/4/1994# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item(2).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item(4).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2073 |
Do do I get the ADO version I have installed
With Exg2antt1 Debug.Print( "ADO Version:" ) Debug.Print( New ADODB.Connection().Version ) End With |
2072 |
DAO, ACCDB, 120
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,2),.get_CellValue(Item,4)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False With New DAO.PrivDBEngine() rs = .OpenDatabase("C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb").OpenRecordset("Orders") End With .DataSource = rs With .Chart .FirstVisibleDate = #8/4/1994# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item(2).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item(4).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2071 |
DAO, MDB, 120
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,2),.get_CellValue(Item,4)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False With New DAO.PrivDBEngine() rs = .OpenDatabase("C:\Program Files\Exontrol\ExG2antt\sample\Access\misc.mdb").OpenRecordset("Orders") End With .DataSource = rs With .Chart .FirstVisibleDate = #8/4/1994# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item(2).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item(4).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2070 |
DAO, MDB
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,2),.get_CellValue(Item,4)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False With New DAO.PrivDBEngine() rs = .OpenDatabase("C:\Program Files\Exontrol\ExG2antt\sample\Access\misc.mdb").OpenRecordset("Orders") End With .DataSource = rs With .Chart .FirstVisibleDate = #8/4/1994# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item(2).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item(4).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2069 |
ADODB, ACCDB, x64
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,2),.get_CellValue(Item,4)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False rs = New ADODB.Recordset() With rs .Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb",1,1) End With .DataSource = rs With .Chart .FirstVisibleDate = #8/4/1994# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item(2).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item(4).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2068 |
ADOR, ACCDB
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,2),.get_CellValue(Item,4)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False rs = New ADODB.Recordset() With rs .Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb",3,3) End With .DataSource = rs With .Chart .FirstVisibleDate = #8/4/1994# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item(2).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item(4).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2067 |
ADODB, MDB
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,2),.get_CellValue(Item,4)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False rs = New ADODB.Recordset() With rs .Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb",3,3) End With .DataSource = rs With .Chart .FirstVisibleDate = #8/4/1994# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item(2).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item(4).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2066 |
ADOR, MDB
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 With .Items .AddBar(Item,"Task",.get_CellValue(Item,2),.get_CellValue(Item,4)) End With End With End Sub Dim rs With Exg2antt1 .BeginUpdate() .ColumnAutoResize = False rs = New ADODB.Recordset() With rs .Open("Orders","Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Program Files\Exontrol\ExG2antt\Sample\Access\misc.accdb",3,3) End With .DataSource = rs With .Chart .FirstVisibleDate = #8/4/1994# .LevelCount = 2 .set_PaneWidth(False,256) End With .Items.AllowCellValueToItemBar = True .Columns.Item(2).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Columns.Item(4).set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .EndUpdate() End With |
2065 |
I am using exCellValueToItemBarProperty, Is it possible to “disable” this synchronisation for one (or several) item (sample-2)
Dim h With Exg2antt1 .BeginUpdate() With .Columns .Add("Tasks") .Add("Start").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Add("End").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) End With With .Chart .FirstVisibleDate = #9/20/2006# .LevelCount = 2 .set_PaneWidth(False,196) .AllowCreateBar = exontrol.EXG2ANTTLib.CreateBarEnum.exCreateBarAuto End With With .Items .AllowCellValueToItemBar = True .AddBar(.AddItem("Task 1"),"Task",#9/21/2006#,#9/24/2006#) h = .AddItem("Task 2") .AddBar(h,"Task",#9/22/2006#,#9/25/2006#) .set_ItemBold(h,True) .CellValueToItemBar(h,1,exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarStart,"newbar") .CellValueToItemBar(h,2,exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarEnd,"newbar") .AddBar(.AddItem("Task 3"),"Task",#9/23/2006#,#9/26/2006#) End With .EndUpdate() End With |
2064 |
I am using exCellValueToItemBarProperty, Is it possible to “disable” this synchronisation for one (or several) item (sample-1)
Dim h With Exg2antt1 .BeginUpdate() With .Columns .Add("Tasks") .Add("Start").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .Add("End").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) End With With .Chart .FirstVisibleDate = #9/20/2006# .LevelCount = 2 .set_PaneWidth(False,196) End With With .Items .AllowCellValueToItemBar = True .AddBar(.AddItem("Task 1"),"Task",#9/21/2006#,#9/24/2006#) h = .AddItem("Task 2") .AddBar(h,"Task",#9/22/2006#,#9/25/2006#) .set_FormatCell(h,1,"``") .set_FormatCell(h,2,"``") .set_ItemBold(h,True) .AddBar(.AddItem("Task 3"),"Task",#9/23/2006#,#9/26/2006#) End With .EndUpdate() End With |
2063 |
How can I use the CRD (eXCRD format)
Dim dih,h With Exg2antt1 .BeginUpdate() .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched .SelBackMode = exontrol.EXG2ANTTLib.BackModeEnum.exTransparent With .Columns.Add("Default") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellFormatLevel,"[b=0]60;1[b=15]:60,((20;""<fgcolor=808080>Dateigröße""[b=1][a=2]:120,2[b=15])/(20;""<fgcolor=808080>Erstellt am""[a=2]:120,3[b=" & _ "15])/(20;""<fgcolor=808080>Zuletzt bearbeitet""[b=4][a=2]:120,4[b=15]))") .AllowSort = False End With .Columns.Add(1).Visible = False With .Columns.Add(2) .Visible = False .Editor.EditType = exontrol.EXG2ANTTLib.EditTypeEnum.EditType .FormatColumn = "1 index `A-Z`" End With With .Columns.Add(3) .Visible = False .Editor.EditType = exontrol.EXG2ANTTLib.EditTypeEnum.EditType .FormatColumn = "1 index ``" End With With .Columns.Add(4) .Visible = False .Editor.EditType = exontrol.EXG2ANTTLib.EditTypeEnum.EditType .FormatColumn = "date(``)" End With dih = 48 .DefaultItemHeight = dih .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesSolid With .Chart .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesSolid .set_PaneWidth(False,256) .LevelCount = 2 .FirstVisibleDate = #1/1/2001# .Bars.Item("Task").OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStackAutoArrange Or exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStack End With With .Items h = .AddItem("") .set_CellValue(h,1,"One") .AddBar(h,"Task",#1/2/2001#,#1/12/2001#,"A") .AddBar(h,"Task",#1/4/2001#,#1/14/2001#,"B") .set_ItemMaxHeight(h,dih) h = .AddItem("") .set_CellValue(h,1,"Two") .AddBar(h,"Task",#1/5/2001#,#1/10/2001#,"A") .AddBar(h,"Task",#1/2/2001#,#1/4/2001#,"B") .AddBar(h,"Task",#1/5/2001#,#1/14/2001#,"B2") .set_ItemMaxHeight(h,dih) h = .AddItem("") .set_CellValue(h,1,"Three") .AddBar(h,"Task",#1/5/2001#,#1/10/2001#,"A") End With .EndUpdate() End With |
2062 |
Type of wraps the cell's caption support (Sample 2)
With Exg2antt1 .BeginUpdate() .HeaderSingleLine = False .HeaderHeight = 36 .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .ColumnAutoResize = False .ScrollBySingleLine = True With .Columns With .Add("Single-Line (exCaptionSingleLine)") .Width = 96 .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueFormat,1) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellSingleLine,-1) End With With .Add("Word-Wrap (exCaptionWordWrap)") .Width = 96 .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueFormat,1) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellSingleLine,0) .FormatColumn = "%0" End With With .Add("Break-Wrap (exCaptionBreakWrap)") .Width = 96 .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueFormat,1) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellSingleLine,1) .FormatColumn = "%0" End With End With With .Items .AddItem("This is the <b>first</b> line.<br>This is the <b>second</b> line.<br>This is the <b>third</b> line.") .AddItem("This is the <b>first</b> line.\r\nThis is the <b>second</b> line.\r\nThis is the <b>third</b> line.") End With .EndUpdate() End With |
2061 |
Type of wraps the cell's caption support (Sample 1)
Dim h With Exg2antt1 .BeginUpdate() .HeaderSingleLine = False .HeaderHeight = 36 .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .ColumnAutoResize = False .ScrollBySingleLine = True .Columns.Add("Default").Width = 128 With .Items h = .AddItem("This is the first line.\r\nThis is the second line.\r\nThis is the third line.") h = .AddItem("This is the <b>first</b> line.<br>This is the <b>second</b> line.<br>This is the <b>third</b> line.") .set_CellValueFormat(h,0,exontrol.EXG2ANTTLib.ValueFormatEnum.exHTML) h = .AddItem("This is the first line.\r\nThis is the second line.\r\nThis is the third line.") .set_CellSingleLine(h,0,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) h = .AddItem("This is the <b>first</b> line.<br>This is the <b>second</b> line.<br>This is the <b>third</b> line.") .set_CellValueFormat(h,0,exontrol.EXG2ANTTLib.ValueFormatEnum.exHTML) .set_CellSingleLine(h,0,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) h = .AddItem("This is the first line.\r\nThis is the second line.\r\nThis is the third line.") .set_CellSingleLine(h,0,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionBreakWrap) h = .AddItem("This is the <b>first</b> line.<br>This is the <b>second</b> line.<br>This is the <b>third</b> line.") .set_CellValueFormat(h,0,exontrol.EXG2ANTTLib.ValueFormatEnum.exHTML) .set_CellSingleLine(h,0,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionBreakWrap) End With .EndUpdate() End With |
2060 |
Can I break the cell's caption using the line break <br> or \r\n (Sample 2)
With Exg2antt1 .BeginUpdate() .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .ColumnAutoResize = False .ScrollBySingleLine = True .Columns.Add("Default").Width = 128 With .Items .set_CellSingleLine(.AddItem("This is the first line.\r\nThis is the second line.\r\nThis is the third line."),0,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionBreakWrap) .AddItem("This is the first line.\r\nThis is the second line.\r\nThis is the third line.") End With .EndUpdate() End With |
2059 |
Can I break the cell's caption using the line break <br> or \r\n (Sample 1)
With Exg2antt1 .BeginUpdate() .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .ColumnAutoResize = False .ScrollBySingleLine = True With .Columns.Add("Default") .Width = 128 .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellSingleLine,1) End With With .Items .AddItem("This is the first line.\r\nThis is the second line.\r\nThis is the third line.") .AddItem("This is the first line.\r\nThis is the second line.\r\nThis is the third line.") End With .EndUpdate() End With |
2058 |
The histogram is showing empty space, when expanding an item. What could be wrong
Dim h With Exg2antt1 .BeginUpdate() .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exGroupLinesOutside With .Chart .LevelCount = 2 .set_PaneWidth(False,128) .FirstVisibleDate = #1/1/2001# .HistogramVisible = True .HistogramHeight = 48 .HistogramView = exontrol.EXG2ANTTLib.HistogramViewEnum.exHistogramNoGrouping Or exontrol.EXG2ANTTLib.HistogramViewEnum.exHistogramLeafItems Or exontrol.EXG2ANTTLib.HistogramViewEnum.exHistogramAllItems .Bars.Item("Task").HistogramPattern = exontrol.EXG2ANTTLib.PatternEnum.exPatternBDiagonal End With .Columns.Add("Column") With .Items h = .AddItem("Project 1") .AddBar(.InsertItem(h,Nothing,"Item 1"),"Task",#1/2/2001#,#1/4/2001#) .AddBar(.InsertItem(h,Nothing,"Item 2"),"Task",#1/3/2001#,#1/5/2001#) .set_ExpandItem(h,True) h = .AddItem("Project 2") .AddBar(.InsertItem(h,Nothing,"Item 1"),"Task",#1/7/2001#,#1/10/2001#) .AddBar(.InsertItem(h,Nothing,"Item 2"),"Task",#1/6/2001#,#1/8/2001#) End With .EndUpdate() End With |
2057 |
How can I change the visual appearance/color of the Filter For ... field
Dim h With Exg2antt1 .BeginUpdate() .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot .BackColorHeader = Color.FromArgb(1,0,0) .ForeColorHeader = Color.FromArgb(255,255,255) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exBackColorFilter,.BackColorHeader) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exForeColorFilter,.ForeColorHeader) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exHeaderFilterBarButton,Color.FromArgb(240,240,240)) .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exCursorHoverColumn,-1) .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Bump With .Columns.Add("Items") .FilterOnType = True .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exNoItems End With With .Items h = .AddItem("Root 1") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") .set_ExpandItem(h,True) h = .AddItem("Root 2") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") End With .EndUpdate() End With |
2056 |
How can I display the cell's caption without spaces on both sides
With Exg2antt1 .BeginUpdate() .ColumnAutoResize = True With .Columns.Add("Default") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueFormat,1) .FormatColumn = "((trim(value) replace ` ` with ` `) replace ` ` with ` `) replace ` ` with `<bgcolor=FF0000> </bgcolor>`" End With With .Items .AddItem("") .AddItem("Item A") .AddItem(" Item B") .AddItem(" Item C ") End With .EndUpdate() End With |
2055 |
How can I highlight the spaces within the column (sample 2)
With Exg2antt1 .BeginUpdate() .ColumnAutoResize = True With .Columns.Add("Default") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueFormat,1) .FormatColumn = "`'` + ( value replace ` ` with `_` ) + `'`" End With With .Items .AddItem("") .AddItem("Item A") .AddItem(" Item B") .AddItem(" Item C ") End With .EndUpdate() End With |
2054 |
How can I highlight the spaces within the column (sample 1)
With Exg2antt1 .BeginUpdate() .ColumnAutoResize = True With .Columns.Add("Default") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueFormat,1) .FormatColumn = "len(value) = 0 ? `<bgcolor=FF0000> </bgcolor>` : ( value replace ` ` with `<bgcolor=FF0000> </bgcolor>` )" End With With .Items .AddItem("") .AddItem("Item A") .AddItem(" Item B") .AddItem(" Item C ") End With .EndUpdate() End With |
2053 |
How can I change the visual aspect of the drop down filter-calendar
With Exg2antt1 .BeginUpdate() .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exBackColorFilter,Color.FromArgb(0,0,1)) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exForeColorFilter,Color.FromArgb(255,255,255)) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exDateScrollRange,Color.FromArgb(255,255,255)) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exDateHeader,.get_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exBackColorFilter)) .set_Background(exontrol.EXG2ANTTLib.BackgroundPartEnum.exDateScrollThumb,Color.FromArgb(128,128,128)) With .Columns.Add("Date") .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exDate .DisplayFilterButton = True .DisplayFilterDate = True .DisplayFilterPattern = False End With .EndUpdate() End With |
2052 |
How can I scroll the chart to ensure that a bar fits the chart's client area
' ButtonClick event - Occurs when user clicks on the cell's button. Private Sub Exg2antt1_ButtonClick(ByVal sender As System.Object,ByVal Item As Integer,ByVal ColIndex As Integer,ByVal Key As Object) Handles Exg2antt1.ButtonClick Dim dEnd,dScroll,dStart,kBar With Exg2antt1 kBar = .Items.get_FirstItemBar(Item) dStart = .Items.get_ItemBar(Item,kBar,exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarStart) dEnd = .Items.get_ItemBar(Item,kBar,exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarEnd) dScroll = .FormatABC("(A+B)/2",dStart,dEnd) .Chart.ScrollTo(dScroll,1) End With End Sub With Exg2antt1 .BeginUpdate() .ShowFocusRect = False .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesDot4 .SelBackMode = exontrol.EXG2ANTTLib.BackModeEnum.exTransparent With .Chart .OverviewVisible = exontrol.EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowDateTimeScaleBottom Or exontrol.EXG2ANTTLib.OverviewVisibleEnum.exOverviewAllowVerticalScroll Or exontrol.EXG2ANTTLib.OverviewVisibleEnum.exOverviewShowAllVisible .OverviewHeight = 26 .FirstVisibleDate = #6/8/2011# .AdjustLevelsToBase = True .set_PaneWidth(False,64) .UnitWidth = 14 .LevelCount = 2 .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesDot4 .SelBackColor = Exg2antt1.SelBackColor .ColumnsFormatLevel = """"":2,(""""/14;1/""""):14" End With With .Columns .Add("Default") With .Add("") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellHasButton,True) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellBackColor,15790320) .Visible = False End With End With With .Items .AddBar(.AddItem("T1"),"Task",#6/9/2011#,#6/17/2011#) .AddBar(.AddItem("T2"),"Task",#1/10/2012#,#1/17/2012#) .AddBar(.AddItem("T3"),"Task",#2/19/2013#,#2/23/2013#) .AddBar(.AddItem("T4"),"Task",#12/19/2014#,#12/23/2014#) End With .EndUpdate() End With |
2051 |
Is it possible to hide completely the list portion
With Exg2antt1 .BeginUpdate() .HeaderHeight = 32 .OnResizeControl = exontrol.EXG2ANTTLib.OnResizeControlEnum.exDisableSplitter Or exontrol.EXG2ANTTLib.OnResizeControlEnum.exResizeChart .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines With .ConditionalFormats.Add("%CS0 = 1") .ApplyToBars = "Task" .BarColor = Color.FromArgb(255,0,0) End With With .Chart .FirstVisibleDate = #6/8/2011# .AdjustLevelsToBase = True .set_PaneWidth(False,0) .LevelCount = 2 .AllowInsideZoom = True With .get_Level(0) .Alignment = exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment .Label = "<b><%d%>-<%mmm%>-<%yyyy%>" .Unit = exontrol.EXG2ANTTLib.UnitEnum.exDay End With With .get_Level(1) .Label = "<%h%>" .Count = 8 .Unit = exontrol.EXG2ANTTLib.UnitEnum.exHour .FormatLabel = "date(int(dvalue)) case (#06/08/2011# : (int(value) case ( 0 : 'Shift <b>1</b><br>23/20'; 8 : 'Shift <b>2</b><br>38/30' ; 16 : '" & _ "Shift <b>3</b><br>24/24' ) ) ; #06/09/2011# : (int(value) case ( 0 : 'Shift <b>1</b><br>15/20'; 8 : 'Shift <b>2</b><br>30/32' ; " & _ "16 : 'Shift <b>3</b><br>26/24' ) ) )" End With .UnitWidth = 64 .NonworkingDays = 0 .ColumnsFormatLevel = "0" .AllowInsideZoom = True .DefaultInsideZoomFormat.InsideUnit = exontrol.EXG2ANTTLib.UnitEnum.exMinute .AllowResizeInsideZoom = False .InsideZoomOnDblClick = False With .InsideZooms .SplitBaseLevel = False .DefaultWidth = 0 End With With .InsideZooms .Add(#6/9/2011 8:00:00 AM#) .Add(#6/9/2011 4:00:00 PM#) End With .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesDot4 End With .Columns.Add("Defaul").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox,True) With .Items .AddBar(.AddItem("T1"),"Task",#6/8/2011 8:00:00 AM#,#6/10/2011#) .AddBar(.AddItem("T2"),"Task",#6/8/2011 4:00:00 PM#,#6/10/2011 8:00:00 AM#) .AddBar(.AddItem("T3"),"Task",#6/9/2011#,#6/10/2011#) .set_CellState(.get_ItemByIndex(1),0,1) End With .EndUpdate() End With |
2050 |
How can I find out what exBarWorkingCount represents
Dim h With Exg2antt1 .BeginUpdate() With .Columns.Add("Tasks") .AllowSizing = False .Width = 42 End With With .Columns.Add("Format") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,258) .FormatColumn = "trim((1:=int((0:=value)/365) ? =:1 + ` year(s) ` : ``) + (1:=int((0:=(=:0 - (=:1*365)))/31) ? =:1 + ` month(s) ` : ``) + (1:=i" & _ "nt((0:=(=:0 - (=:1*31)))/7) ? =:1 + ` week(s) ` : ``) + (1:=int((0:=(=:0 - (=:1*7)))/1) ? =:1 + ` day(s) ` : ``) + (1:=int((0:=(" & _ "=:0 - =:1 + 1/24/60/60/2))*24) ? =:1 + ` hour(s) ` : ``) + (1:=int((0:=(=:0*24 - =:1))*60) ? =:1 + ` min(s) ` : ``) + (1:=int((0" & _ ":=(=:0*60 - =:1))*60) ? =:1 + ` sec(s)` : ``))" End With With .Columns.Add("Value") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,258) .SortType = exontrol.EXG2ANTTLib.SortTypeEnum.SortNumeric .Editor.EditType = exontrol.EXG2ANTTLib.EditTypeEnum.EditType End With .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesSolid .SelBackColor = Color.FromArgb(204,232,255) .SelForeColor = Color.FromArgb(0,0,0) With .Chart .SelBackColor = Exg2antt1.SelBackColor .FirstVisibleDate = #4/6/2009# .set_PaneWidth(False,256) .LevelCount = 2 .UnitScale = exontrol.EXG2ANTTLib.UnitEnum.exHour .NonworkingHours = 15728767 .ShowNonworkingDates = False .ShowNonworkingUnits = False .ShowNonworkingHours = False With .Bars.Item("Task") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount,True) End With .AllowLinkBars = False .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesSolid .get_Level(0).DrawGridLines = True .ResizeUnitScale = exontrol.EXG2ANTTLib.UnitEnum.exMinute .ResizeUnitCount = 15 .set_Label(exontrol.EXG2ANTTLib.UnitEnum.exMinute,"<|><%nn%><|><%h%>:<%nn%> <%AM/PM%><|><%d3%>, <%m3%> <%d%>, '<%yy%> <%h%>:<%nn%> <%AM/PM%><|><%dddd%>, <%mmmm%> <%d%>, <%yyyy%> " & _ "<%h%>:<%nn%> <%AM/PM%><||>15") .AllowZoomOnFly = exontrol.EXG2ANTTLib.ZoomOnFlyEnum.exZoomOnFlyIncludeNeighborItems Or exontrol.EXG2ANTTLib.ZoomOnFlyEnum.exZoomOnFly .BackColorZoomOnFly = Color.FromArgb(255,255,0) End With .Items.AllowCellValueToItemBar = True With .Items h = .AddItem("") .set_SelectableItem(h,False) .set_SortableItem(h,False) .AddBar(.AddItem("T1"),"Task",#4/6/2009 10:00:00 AM#,#4/6/2009 1:00:00 PM#) .AddBar(.AddItem("T2"),"Task",#4/6/2009 10:00:00 AM#,#4/6/2009 4:00:00 PM#) .AddBar(.AddItem("T3"),"Task",#4/6/2009 10:00:00 AM#,#4/6/2009 7:00:00 PM#) h = .AddItem("") .set_SelectableItem(h,False) .set_SortableItem(h,False) End With .EndUpdate() End With |
2049 |
How can I hide the filter bar description
With Exg2antt1 .BeginUpdate() With .Columns.Add("Filter") .DisplayFilterButton = True .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "B" End With With .Items .AddItem("A") .AddItem("B") .AddItem("C") End With .ApplyFilter() .FilterBarHeight = 0 .EndUpdate() End With |
2048 |
How can I add a break bar
Dim h With Exg2antt1 .BeginUpdate() With .Columns.Add("Tasks") .AllowSizing = False .Width = 42 End With With .Columns.Add("Working") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,258) .FormatColumn = "((1:=int(0:= (value))) != 0 ? (=:1 + ' day(s)') : '') + (=:1 ? ' ' : '' ) + ((1:=int(0:=((=:0 - =:1 + 1/24/60/60/2)*24))) != 0 " & _ "? =:1 + ' hour(s)' : '' ) + (=:1 ? ' ' : '' ) + ((1:=round((=:0 - =:1)*60)) != 0 ? =:1 + ' min(s)' : '')" End With .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesSolid .SelBackColor = Color.FromArgb(204,232,255) .SelForeColor = Color.FromArgb(0,0,0) With .Chart .SelBackColor = Exg2antt1.SelBackColor .FirstVisibleDate = #4/6/2009# .set_PaneWidth(False,164) .LevelCount = 2 .UnitScale = exontrol.EXG2ANTTLib.UnitEnum.exHour .NonworkingHours = 15728767 .ShowNonworkingDates = False .ShowNonworkingUnits = False .ShowNonworkingHours = False With .Bars.Add("Task:Split") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount,True) .Shortcut = "Task" End With .AllowLinkBars = False .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesSolid .get_Level(0).DrawGridLines = True .ResizeUnitScale = exontrol.EXG2ANTTLib.UnitEnum.exMinute .ResizeUnitCount = 15 .set_Label(exontrol.EXG2ANTTLib.UnitEnum.exMinute,"<|><%nn%><|><%h%>:<%nn%> <%AM/PM%><|><%d3%>, <%m3%> <%d%>, '<%yy%> <%h%>:<%nn%> <%AM/PM%><|><%dddd%>, <%mmmm%> <%d%>, <%yyyy%> " & _ "<%h%>:<%nn%> <%AM/PM%><||>15") .AllowZoomOnFly = exontrol.EXG2ANTTLib.ZoomOnFlyEnum.exZoomOnFlyIncludeNeighborItems Or exontrol.EXG2ANTTLib.ZoomOnFlyEnum.exZoomOnFly .BackColorZoomOnFly = Color.FromArgb(255,255,0) .AllowNonworkingBars = True End With .Items.AllowCellValueToItemBar = True With .Items .AddItem("") h = .AddItem("T1") .set_ItemNonworkingUnits(h,False,"(weekday(value) in (0,6)) or (timeF(value) < `07:00:00`) or (timeF(value) >= `20:00:00`) ") .AddBar(h,"",#4/6/2009 7:30:00 AM#,#4/6/2009 9:30:00 AM#,"A","<c><font ;4>break<br>bar") .set_ItemBar(h,"A",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarTreatAsNonworking,True) .AddBar(h,"Task",#4/6/2009 10:00:00 AM#,#4/6/2009 0:00:00 PM#) .AddBar(.AddItem("T2"),"Task",#4/6/2009 10:00:00 AM#,#4/6/2009 5:45:00 PM#) .AddItem("") End With .EndUpdate() End With |
2047 |
It seems the ResizeUnitCount have no effect on the ZoomOnFly feature, is it normal
With Exg2antt1 .BeginUpdate() With .Columns.Add("Tasks") .AllowSizing = False .Width = 42 End With With .Columns.Add("Working") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,258) .FormatColumn = "((1:=int(0:= (value))) != 0 ? (=:1 + ' day(s)') : '') + (=:1 ? ' ' : '' ) + ((1:=int(0:=((=:0 - =:1 + 1/24/60/60/2)*24))) != 0 " & _ "? =:1 + ' hour(s)' : '' ) + (=:1 ? ' ' : '' ) + ((1:=round((=:0 - =:1)*60)) != 0 ? =:1 + ' min(s)' : '')" End With .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesSolid .SelBackColor = Color.FromArgb(204,232,255) .SelForeColor = Color.FromArgb(0,0,0) With .Chart .SelBackColor = Exg2antt1.SelBackColor .FirstVisibleDate = #4/6/2009# .set_PaneWidth(False,164) .LevelCount = 2 .UnitScale = exontrol.EXG2ANTTLib.UnitEnum.exHour .NonworkingHours = 15728767 .ShowNonworkingDates = False .ShowNonworkingUnits = False .ShowNonworkingHours = False With .Bars.Item("Task") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount,True) End With .AllowLinkBars = False .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exRowLines .GridLineStyle = exontrol.EXG2ANTTLib.GridLinesStyleEnum.exGridLinesSolid .get_Level(0).DrawGridLines = True .ResizeUnitScale = exontrol.EXG2ANTTLib.UnitEnum.exMinute .ResizeUnitCount = 15 .set_Label(exontrol.EXG2ANTTLib.UnitEnum.exMinute,"<|><%nn%><|><%h%>:<%nn%> <%AM/PM%><|><%d3%>, <%m3%> <%d%>, '<%yy%> <%h%>:<%nn%> <%AM/PM%><|><%dddd%>, <%mmmm%> <%d%>, <%yyyy%> " & _ "<%h%>:<%nn%> <%AM/PM%><||>15") .AllowZoomOnFly = exontrol.EXG2ANTTLib.ZoomOnFlyEnum.exZoomOnFlyIncludeNeighborItems Or exontrol.EXG2ANTTLib.ZoomOnFlyEnum.exZoomOnFly .BackColorZoomOnFly = Color.FromArgb(255,255,0) End With .Items.AllowCellValueToItemBar = True With .Items .AddItem("") .AddBar(.AddItem("T1"),"Task",#4/6/2009 10:00:00 AM#,#4/6/2009 0:00:00 PM#) .AddBar(.AddItem("T2"),"Task",#4/6/2009 10:00:00 AM#,#4/6/2009 5:45:00 PM#) .AddItem("") End With .EndUpdate() End With |
2046 |
Export Data in HTML format
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem With Exg2antt1 With .Items .set_ItemBold(Item,True) .AddBar(Item,"Summary",.get_CellValue(Item,2),.get_CellValue(Item,4)) .DefineSummaryBars(Item,"",-3,"") End With End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 With .Items i = .get_ItemToIndex(Item) .AddBar(Item,"Task",#1/2/2008#,#1/9/2008#,"") .set_ItemBar(Item,"",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarMove,i) .set_ItemBar(Item,"",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarDuration,i) End With End With End Sub Dim sFile With Exg2antt1 .BeginUpdate() .BackColorAlternate = Color.FromArgb(240,240,240) .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "(( ( value replace `[<b>` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replace `</b>]` with ` </b></bgcolor></fgcolor>` replace " & _ "`[<s>` with `<bgcolor=C0C0C0><fgcolor=FFFFFF> ` replace `</s>]` with ` </fgcolor></bgcolor>` ) + `<r><fgcolor=808080>` + ( matc" & _ "hitemcount < 0 ? ( ( len(value) ? `` : `` ) + `<r>` + abs(matchitemcount + 1) + ` result(s)` ) : (`<r><fgcolor=808080>`+ itemcou" & _ "nt + ` item(s)`) )))" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCompact Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarShowCloseIfRequired Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarSingleLine Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible .FilterBarPromptType = exontrol.EXG2ANTTLib.FilterPromptEnum.exFilterPromptContainsAny .SingleSort = False .AllowGroupBy = True .BackColorSortBar = .BackColor .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines With .VisualAppearance .Add(1,"gBFLBCJwBAEHhEJAAEhABOUGACAADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJwFgmEgADCMQwAFBIbhrE4ZBjHGQRUgyI43RhHUBzV" & _ "IUBxDEaTZLlEYJBgeHYhDJPcaUVDcWQHGyeZwjSgpKoWSJIU5NcggPDgEwTKCmKlTAKoSzJMyEmwWRAdVTZLSEaxierKPhyWT/XgAF4PfDFKRXFqXY5mKZJFqKOI8TxI" & _ "NgxPQMGyrBqraLqKwQGrGCQKSBhUZ3dS2JR3OSlYRuQAMVgOXoDZhPWZXbDtSzPE63NgtOR5DiGWalABoeoxRa9cz3ViCJSrGTqIoINIzZLHFQbPpdAYdP6BeIjXhhZx" & _ "BBuLZXmEOh9CcNoni2N4MjWVodh+DpfBeLJinsWR9AyYwVAkGBhEAFphGiRogDEGBamkFgtjcZgHiMbgehYaQhAIEIREAaQYkcQZUHIGRUGQDBOEaBAhDYDxGkMZAkCg" & _ "eoagYZAYEYAYIAWGhemICIFj8WIiCiFR5gkIhogmBoKGKJx2C6C5hniMgggqYwog0UoNGMZJiDiCZRgOLY0ECUAQICA==") .RenderType = &Hf0000000ui End With With .Chart .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines .set_PaneWidth(False,196) .LevelCount = 2 .FirstVisibleDate = #1/1/2008# .FirstWeekDay = exontrol.EXG2ANTTLib.WeekDayEnum.exMonday With .Bars.Item("Summary") .StartShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .EndShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .Shape = exontrol.EXG2ANTTLib.ShapeBarEnum.exShapeSolid .Color32 = &H1808080 .Height = 7 .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%513%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With With .Bars.Item("Task") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=(%2-%1) in (3,5) ? %513 : `` %>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With End With With .ConditionalFormats.Add("(%2 - %1) = 3","K3") .ForeColor = Color.FromArgb(255,0,0) .BarColor = .ForeColor .ApplyToBars = "Task" End With With .ConditionalFormats.Add("(%2 - %1) = 5","K5") .ForeColor = Color.FromArgb(0,255,0) .BarColor = .ForeColor .ApplyToBars = "Task" End With With .Columns .Add("Tasks").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox,True) With .Add("Start") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey,"") End With With .Add("End") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey,"") End With End With With .Items .AllowCellValueToItemBar = True .AddItem("Task A") .AddItem("Task A") .AddItem("Task A") .AddItem("Task A") .AddItem("Task B") .AddItem("Task B") .AddItem("Task B") .AddItem("Task C") End With .Columns.Item("Tasks").SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .EndUpdate() sFile = "c:/temp/export.html" .Export(sFile,"vis") With New SHDocVw.ShellBrowserWindow() .Navigate2(sFile) End With End With |
2045 |
Export Data in CSV format
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 With .Items i = .get_ItemToIndex(Item) .AddBar(Item,"Task",#1/2/2008#,#1/9/2008#,"") .set_ItemBar(Item,"",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarMove,i) .set_ItemBar(Item,"",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarDuration,i) End With End With End Sub With Exg2antt1 .BeginUpdate() .BackColorAlternate = Color.FromArgb(240,240,240) .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exAllLines .HeaderAppearance = exontrol.EXG2ANTTLib.AppearanceEnum.Etched .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "(( ( value replace `[<b>` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replace `</b>]` with ` </b></bgcolor></fgcolor>` replace " & _ "`[<s>` with `<bgcolor=C0C0C0><fgcolor=FFFFFF> ` replace `</s>]` with ` </fgcolor></bgcolor>` ) + `<r><fgcolor=808080>` + ( matc" & _ "hitemcount < 0 ? ( ( len(value) ? `` : `` ) + `<r>` + abs(matchitemcount + 1) + ` result(s)` ) : (`<r><fgcolor=808080>`+ itemcou" & _ "nt + ` item(s)`) )))" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCompact Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarShowCloseIfRequired Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarSingleLine Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible .FilterBarPromptType = exontrol.EXG2ANTTLib.FilterPromptEnum.exFilterPromptContainsAny With .Chart .set_PaneWidth(False,196) .LevelCount = 2 .FirstVisibleDate = #1/1/2008# With .Bars.Item("Task") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=(%2-%1) in (3,5) ? %513 : `` %>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With End With With .ConditionalFormats.Add("(%2 - %1) = 3","K3") .ForeColor = Color.FromArgb(255,0,0) .BarColor = .ForeColor .ApplyToBars = "Task" End With With .ConditionalFormats.Add("(%2 - %1) = 5","K5") .ForeColor = Color.FromArgb(0,255,0) .BarColor = .ForeColor .ApplyToBars = "Task" End With With .Columns .Add("Tasks").set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox,True) With .Add("Start") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,1) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey,"") End With With .Add("End") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,2) .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey,"") End With End With With .Items .AllowCellValueToItemBar = True .AddItem("Task A") .AddItem("Task A") .AddItem("Task A") .AddItem("Task A") .AddItem("Task B") .AddItem("Task B") .AddItem("Task B") .AddItem("Task C") End With .EndUpdate() Debug.Print( .Export("","vis") ) End With |
2044 |
I want to be able to detect when a user clicks on a row in the chart that is not populated
' MouseMove event - Occurs when the user moves the mouse. Private Sub Exg2antt1_MouseMoveEvent(ByVal sender As System.Object,ByVal Button As Short,ByVal Shift As Short,ByVal X As Integer,ByVal Y As Integer) Handles Exg2antt1.MouseMoveEvent Dim col,date,hit,item,sMessage With Exg2antt1 item = .get_ItemFromPoint(-1,-1,col,hit) date = .Chart.get_DateFromPoint(-1,-1) sMessage = .FormatABC("(not(A = 0) ? `chart` : `list`) + ` ` + (not(B = 0) ? `item` : `empty`) ",date,item) Debug.Print( sMessage ) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .set_PaneWidth(False,128) .LevelCount = 2 .FirstVisibleDate = #1/1/2018# End With .Columns.Add("Tasks") With .Items .AddBar(.AddItem("Task 1"),"Task",#1/2/2018#,#1/12/2018#) .AddBar(.AddItem("Task 2"),"Task",#1/3/2018#,#1/13/2018#) .AddBar(.AddItem("Task 3"),"Task",#1/4/2018#,#1/14/2018#) End With .EndUpdate() End With |
2043 |
Is it possible to have multiple calendars. A calendar for each row for example. Reason : some of our lines work 2 shifts but some also have a night shift
Dim h,sCalendar1,sCalendar2,sCalendar3,sCalendar4 With Exg2antt1 .BeginUpdate() .Columns.Add("Tasks") With .Columns.Add("Working") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,258) .FormatColumn = "((1:=int(0:=( 24*int(value) + (value - int(value) + 1/24/60/60/2)*24))) != 0 ? =:1 + ' hour(s)' : '' ) + (=:1 ? ' ' : '' ) + ((" & _ "1:=round((=:0 - =:1)*60)) != 0 ? =:1 + ' min(s)' : '')" End With With .Chart .FirstVisibleDate = #4/6/2009# .set_PaneWidth(False,148) .LevelCount = 2 .ShowNonworkingUnits = False .ShowNonworkingDates = False With .Bars .Add("Task:Split").Shortcut = "Task" .Item("Task").set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarKeepWorkingCount,True) End With .set_Label(exontrol.EXG2ANTTLib.UnitEnum.exHour,"<%h%><||><||>65536") .get_Level(0).FormatLabel = "`<font small fonts;6>` + value" .get_Level(1).FormatLabel = "len(value) = 2 ? (`<font small fonts;4>` + (value left 1) + `<br>` + (value right 1) ) : (`<font small fonts;4>` + ` <br>` + (v" & _ "alue left 1) + `` )" .UnitScale = exontrol.EXG2ANTTLib.UnitEnum.exHour .UnitWidth = 9 End With .Items.AllowCellValueToItemBar = True With .Items sCalendar1 = "weekday(value) in (0,6) or (hour(value) < 6) or (hour(value) > 18)" h = .AddItem("Shift 1") .set_ItemNonworkingUnits(h,False,sCalendar1) .AddBar(h,"Task",#4/6/2009#,#4/7/2009#) h = .AddItem("Shift 1") .set_ItemNonworkingUnits(h,False,sCalendar1) .AddBar(h,"Task",#4/6/2009#,#4/8/2009#) sCalendar2 = "weekday(value) in (0,6) or (hour(value) < 8) or (hour(value) > 14)" h = .AddItem("Shift 2") .set_ItemNonworkingUnits(h,False,sCalendar2) .AddBar(h,"Task",#4/6/2009#,#4/7/2009#) h = .AddItem("Shift 2") .set_ItemNonworkingUnits(h,False,sCalendar2) .AddBar(h,"Task",#4/6/2009#,#4/8/2009#) sCalendar3 = "weekday(value) in (0,6) or 0 = ( hour(value) mod 3 ) " h = .AddItem("Shift 3") .set_ItemNonworkingUnits(h,False,sCalendar3) .AddBar(h,"Task",#4/6/2009#,#4/7/2009#) h = .AddItem("Shift 3") .set_ItemNonworkingUnits(h,False,sCalendar3) .AddBar(h,"Task",#4/6/2009#,#4/8/2009#) sCalendar4 = "weekday(value) in (0,6)" h = .AddItem("Shift 3") .set_ItemNonworkingUnits(h,False,sCalendar4) .AddBar(h,"Task",#4/6/2009#,#4/7/2009#) h = .AddItem("Shift 3") .set_ItemNonworkingUnits(h,False,sCalendar4) .AddBar(h,"Task",#4/6/2009#,#4/8/2009#) End With .EndUpdate() End With |
2042 |
Is it possible to check multiple-items at once
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim bHasParent With Exg2antt1 bHasParent = .FormatABC("value != 0",.Items.get_ItemParent(Item)) With .Items .set_CellHasCheckBox(Item,0,False) End With End With End Sub Dim h,hChild With Exg2antt1 .BeginUpdate() .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot With .Columns.Add("Tasks") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueFormat,1) .FormatColumn = "value + (%CS0 = 1 ? `<r><fgcolor=808080>(checked)` : ``)" End With .HeaderVisible = exontrol.EXG2ANTTLib.HeaderVisibleEnum.exHeaderVisibleExtendLevels .SingleSel = False With .Items h = .AddItem("Project") hChild = .InsertItem(h,Nothing,"Task 1") hChild = .InsertItem(h,Nothing,"Task 2") hChild = .InsertItem(h,Nothing,"Task 3") .set_ExpandItem(h,True) .set_LockedItemCount(exontrol.EXG2ANTTLib.VAlignmentEnum.exTop,1) .set_CellValue(.get_LockedItem(exontrol.EXG2ANTTLib.VAlignmentEnum.exTop,0),0,"<c>Select multiple items and press the <b>SPACE</b> key") End With .EndUpdate() End With |
2041 |
How can I prevent changing the start/end colors of the bar, when ItemBar(exBarColor) property is applied
Dim h With Exg2antt1 .BeginUpdate() .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") .VisualAppearance.Add(1,"E:\Exontrol\ExButton\sample\EBN\Assorted\bhframe.ebn") .Chart.set_PaneWidth(False,96) With .Chart.Bars .AddShapeCorner(12345,1) .AddShapeCorner(999,2) .AddShapeCorner(1049,3) With .Add("T1") .StartShape = &H3020 Or exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconVBar Or exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconRight .EndShape = &H3e0 Or exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconLeft .Pattern = exontrol.EXG2ANTTLib.PatternEnum.exPatternNDot .StartColor = Color.FromArgb(0,255,0) .Color32 = &H1000000 .EndColor = Color.FromArgb(255,0,0) .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=`<font ;6> ` + %0 + ``%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With With .Add("T2") .StartShape = &H3020 Or exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconVBar Or exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconRight .EndShape = &H400 Or exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconVBar Or exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconRight .Pattern = exontrol.EXG2ANTTLib.PatternEnum.exPatternNDot .StartColor32 = -1 .Color32 = &H1000000 .EndColor32 = -1 .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=`<font ;6> ` + %0 + ``%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With End With .Chart.FirstVisibleDate = #1/1/2001# .Columns.Add("Column") With .Items h = .AddItem("Item 1") .AddBar(h,"T1",#1/2/2001#,#1/4/2001#) h = .AddItem("Item 2") .AddBar(h,"T1",#1/2/2001#,#1/4/2001#) .set_ItemBar(h,"",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarColor,65280) h = .AddItem("Item 3") .AddBar(h,"T1",#1/2/2001#,#1/4/2001#) .set_ItemBar(h,"",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarColor,255) h = .AddItem("Item 4") .AddBar(h,"T2",#1/2/2001#,#1/4/2001#) h = .AddItem("Item 5") .AddBar(h,"T2",#1/2/2001#,#1/4/2001#) .set_ItemBar(h,"",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarColor,65280) h = .AddItem("Item 6") .AddBar(h,"T2",#1/2/2001#,#1/4/2001#) .set_ItemBar(h,"",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarColor,255) End With .EndUpdate() End With |
2040 |
How can I get the icon from the cell when using the Items.CellImages property (icon index)
' MouseMove event - Occurs when the user moves the mouse. Private Sub Exg2antt1_MouseMoveEvent(ByVal sender As System.Object,ByVal Button As Short,ByVal Shift As Short,ByVal X As Integer,ByVal Y As Integer) Handles Exg2antt1.MouseMoveEvent Dim c,hit,i With Exg2antt1 i = .get_ItemFromPoint(-1,-1,c,hit) Debug.Print( .FormatABC("( 0x44 = ( value bitand 0x44 ) ) ? ( ( (value bitand 0xFFFF0000) bitshift 16 ) array B split `,` ) : `no image`",hit,.Items.get_CellImages(i,c)) ) End With End Sub With Exg2antt1 .BeginUpdate() .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") .Chart.set_PaneWidth(True,0) .Columns.Add("Default") With .Items .set_CellImages(.AddItem("Item 1"),0,"3,2,1") .set_CellImages(.AddItem("Item 2"),0,"2,3") .set_CellImages(.AddItem("Item 3"),0,"2,") End With .EndUpdate() End With |
2039 |
How can I get the icon from the cell when using the Items.CellImages property (icon position within the cell)
' MouseMove event - Occurs when the user moves the mouse. Private Sub Exg2antt1_MouseMoveEvent(ByVal sender As System.Object,ByVal Button As Short,ByVal Shift As Short,ByVal X As Integer,ByVal Y As Integer) Handles Exg2antt1.MouseMoveEvent Dim c,hit,i With Exg2antt1 i = .get_ItemFromPoint(-1,-1,c,hit) Debug.Print( .FormatABC("( 0x44 = ( value bitand 0x44 ) ) ? 1 + ( (value bitand 0xFFFF0000) bitshift 16 ) : `no image`",hit) ) End With End Sub With Exg2antt1 .BeginUpdate() .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") .Chart.set_PaneWidth(True,0) .Columns.Add("Default") With .Items .set_CellImages(.AddItem("Item 1"),0,"3,2,1") .set_CellImages(.AddItem("Item 2"),0,"2,3") .set_CellImages(.AddItem("Item 3"),0,"2") End With .EndUpdate() End With |
2038 |
I have an EBN bar. Now if I apply an additional color to the bar, e,g, yellow, the bar is displayed as "dark yellow", which I assume is due to the black EBN color. How can I get the more "bright yellow" color
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem Dim l With Exg2antt1 With .Items .set_ItemDividerLine(Item,exontrol.EXG2ANTTLib.DividerLineEnum.EmptyLine) .AddBar(Item,"Summary",#12/2/2017#,#12/2/2017#) .DefineSummaryBars(Item,"",-3,"") l = .get_GroupItem(Item) .set_CellSingleLine(Item,l,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) .set_CellBold(Item,l,True) .set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With .Chart.set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/10/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .VisualAppearance .Add(1,"gBFLBCJwBAEHhEJAAEhABOUGACAADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJwFgmEgADCMQwAFBIbhrE4ZBjHGQRUgyI43RhHUBzV" & _ "IUBxDEaTZLlEYJBgeHYhDJPcaUVDcWQHGyeZwjSgpKoWSJIU5NcggPDgEwTKCmKlTAKoSzJMyEmwWRAdVTZLSEaxierKPhyWT/XgAF4PfDFKRXFqXY5mKZJFqKOI8TxI" & _ "NgxPQMGyrBqraLqKwQGrGCQKSBhUZ3dS2JR3OSlYRuQAMVgOXoDZhPWZXbDtSzPE63NgtOR5DiGWalABoeoxRa9cz3ViCJSrGTqIoINIzZLHFQbPpdAYdP6BeIjXhhZx" & _ "BBuLZXmEOh9CcNoni2N4MjWVodh+DpfBeLJinsWR9AyYwVAkGBhEAFphGiRogDEGBamkFgtjcZgHiMbgehYaQhAIEIREAaQYkcQZUHIGRUGQDBOEaBAhDYDxGkMZAkCg" & _ "eoagYZAYEYAYIAWGhemICIFj8WIiCiFR5gkIhogmBoKGKJx2C6C5hniMgggqYwog0UoNGMZJiDiCZRgOLY0ECUAQICA==") .RenderType = &Hf0000000ui End With With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,342) With .Bars.Item("Summary") .StartShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .EndShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .Shape = exontrol.EXG2ANTTLib.ShapeBarEnum.exShapeSolid .Color32 = &H1ff0000 .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%513%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With End With With .Columns .Add("C1") .Add("C2") .Add("C3") With .Add("Pos") .FormatColumn = "1 pos ``" .AllowGroupBy = False .Position = 0 .Width = 48 .AllowSizing = False End With End With .SortBarVisible = True .SortBarCaption = "Drag a <b>column</b> header here to group by that column." .AllowGroupBy = True .HasLines = exontrol.EXG2ANTTLib.HierarchyLineEnum.exNoLine .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exNoLinesAtRoot With .Items h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") End With With .Columns.Item(0) .SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending End With .EndUpdate() End With |
2037 |
Is it possible to change the visual appearance of the position signs when user changes the column's position by drag and drop
|
2036 |
Overlaid-Types
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim barName With Exg2antt1 With .Items barName = .get_ItemData(Item) .AddBar(Item,barName,#1/2/2001#,#1/4/2001#,"A1") .AddBar(Item,barName,#1/3/2001#,#1/5/2001#,"A2") .AddBar(Item,barName,#1/4/2001#,#1/7/2001#,"A3") .AddBar(Item,barName,#1/5/2001#,#1/8/2001#,"A4") End With End With End Sub Dim h With Exg2antt1 .BeginUpdate() .DefaultItemHeight = 22 .Columns.Add("Task") .ScrollBySingleLine = True .BackColorAlternate = Color.FromArgb(240,240,240) .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exHLines With .Chart .DrawGridLines = exontrol.EXG2ANTTLib.GridLinesEnum.exHLines .ShowNonworkingDates = False .set_PaneWidth(False,164) .FirstVisibleDate = #12/28/2000# .LevelCount = 2 .Bars.Copy("Task","Intersect").Color = Color.FromArgb(255,0,0) .Bars.Item("Task").OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsNone With .Bars.Copy("Task","Task-Transparent") .OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsNone .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarTransparent,50) .Pattern = exontrol.EXG2ANTTLib.PatternEnum.exPatternBox .Color = Color.FromArgb(0,0,0) .StartColor = Color.FromArgb(80,80,255) .EndColor = .StartColor End With .Bars.Copy("Task","Task-Offset").OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsOffset With .Bars.Copy("Task","Task-OffsetTransparent") .OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsTransparent Or exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsOffset .set_Overlaid(exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsTransparent,75) End With With .Bars.Copy("Task","Task-Intersect") .OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsIntersect .set_Overlaid(exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsIntersect,"Intersect") End With .Bars.Copy("Task","Task-Stack").OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStack With .Bars.Copy("Task","Task-StackAutoArrange") .OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStackAutoArrange Or exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStack .Color = Color.FromArgb(255,0,0) .OverlaidGroup = "Task" End With With .Bars.Copy("Task","Task-Cascade") .OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsCascade .Color = Color.FromArgb(255,0,0) .OverlaidGroup = "Task" End With With .Bars.Copy("Task","Task-Strict") .OverlaidType = exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStrict Or exontrol.EXG2ANTTLib.OverlaidBarsTypeEnum.exOverlaidBarsStack .OverlaidGroup = "Task" .Color = Color.FromArgb(255,0,0) End With End With With .Items .InsertItem(0,"Task","Overlaid-None") .InsertItem(0,"Task-Transparent","Overlaid-Semi-Transparent") .InsertItem(0,"Task-Offset","Overlaid-Offset") .InsertItem(0,"Task-OffsetTransparent","Overlaid-OffsetTransparent") .InsertItem(0,"Task-Intersect","Overlaid-Intersect") .InsertItem(0,"Task-Stack","Overlaid-Stack") h = .InsertItem(0,"Task-StackAutoArrange","Overlaid-StackAutoArrange") .AddBar(h,"Task",#1/7/2001#,#1/9/2001#,"T1") .AddBar(h,"Task",#1/3/2001#,#1/5/2001#,"T2") .AddBar(h,"Task",#1/4/2001#,#1/7/2001#,"T3") .AddBar(h,"Task",#1/5/2001#,#1/8/2001#,"T4") h = .InsertItem(0,"Task-Cascade","Overlaid-Cascade") .AddBar(h,"Task",#1/7/2001#,#1/9/2001#,"T1") .AddBar(h,"Task",#1/3/2001#,#1/5/2001#,"T2") .AddBar(h,"Task",#1/4/2001#,#1/7/2001#,"T3") .AddBar(h,"Task",#1/5/2001#,#1/8/2001#,"T4") .set_ItemBar(h,"<A*>",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarOverlaidKey,"A") .set_ItemBar(h,"<T*>",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarOverlaidKey,"T") h = .InsertItem(0,"Task","Overlaid-StackStrict") .AddBar(h,"Task-Strict",#1/7/2001#,#1/9/2001#,"T1") .set_ItemBar(0,"<*>",exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%9%>") End With .EndUpdate() End With |
2035 |
FilterBarCaption ALLUI Keyword ( sample 3, result, leaf )
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem Dim l,val With Exg2antt1 With .Items .set_ItemBackColor(Item,Color.FromArgb(240,240,240)) val = .get_CellValue(Item,.get_GroupItem(Item)) .set_CellState(Item,.get_GroupItem(Item),Exg2antt1.FormatABC("A = `Checked` ? 1 : 0",val)) End With With .Items .set_ItemDividerLine(Item,exontrol.EXG2ANTTLib.DividerLineEnum.EmptyLine) .AddBar(Item,"Summary",#12/2/2017#,#12/2/2017#) .DefineSummaryBars(Item,"",-3,"") l = .get_GroupItem(Item) .set_CellSingleLine(Item,l,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) .set_CellBold(Item,l,True) End With .Chart.set_ItemBackColor(Item,Color.FromArgb(240,240,240)) End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 i = .FormatABC("value + 1",.Items.get_ItemToIndex(Item)) .Items.set_CellImage(Item,3,i) .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() .VisualAppearance.Add(1,"gBFLBCJwBAEHhEJAAEhABOUGACAADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJwFgmEgADCMQwAFBIbhrE4ZBjHGQRUgyI43RhHUBzV" & _ "IUBxDEaTZLlEYJBgeHYhDJPcaUVDcWQHGyeZwjSgpKoWSJIU5NcggPDgEwTKCmKlTAKoSzJMyEmwWRAdVTZLSEaxierKPhyWT/XgAF4PfDFKRXFqXY5mKZJFqKOI8TxI" & _ "NgxPQMGyrBqraLqKwQGrGCQKSBhUZ3dS2JR3OSlYRuQAMVgOXoDZhPWZXbDtSzPE63NgtOR5DiGWalABoeoxRa9cz3ViCJSrGTqIoINIzZLHFQbPpdAYdP6BeIjXhhZx" & _ "BBuLZXmEOh9CcNoni2N4MjWVodh+DpfBeLJinsWR9AyYwVAkGBhEAFphGiRogDEGBamkFgtjcZgHiMbgehYaQhAIEIREAaQYkcQZUHIGRUGQDBOEaBAhDYDxGkMZAkCg" & _ "eoagYZAYEYAYIAWGhemICIFj8WIiCiFR5gkIhogmBoKGKJx2C6C5hniMgggqYwog0UoNGMZJiDiCZRgOLY0ECUAQICA==") With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) With .Bars.Item("Summary") .StartShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .EndShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .Shape = exontrol.EXG2ANTTLib.ShapeBarEnum.exShapeSolid .Color32 = &H1000000 .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%513%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With End With .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Check") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox,True) .DisplayFilterButton = True .DisplayFilterPattern = False .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exCheck End With With .Columns.Add("Image") .DisplayFilterButton = True .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exImage .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 rpos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") h = .AddItem("Item B") .set_CellValue(h,1,"Sub-Item B") .set_CellState(h,2,1) .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "(( ( allui replace `[<b>` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replace `</b>]` with ` </b></bgcolor></fgcolor>` replace " & _ "`[<s>` with `<bgcolor=C0C0C0><fgcolor=FFFFFF> ` replace `</s>]` with ` </fgcolor></bgcolor>` ) + `<r><fgcolor=808080>` + ( matc" & _ "hitemcount < 0 ? ( ( len(value) ? `` : `` ) + `<r>` + leafitemcount + ` result(s)` ) : (`<r><fgcolor=808080>`+ leafitemcount + `" & _ " item(s)`) )))" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible .AllowGroupBy = True .SortBarVisible = True With .Columns.Item(2) .FormatColumn = "%CS2 ? `Checked` : `Unchecked`" .SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending End With .EndUpdate() End With |
2034 |
A black portion is shown while I am using the BackColorAlternate with EBN colors. What can I do
With Exg2antt1 .BeginUpdate() .ColumnAutoResize = True .DefaultItemHeight = 20 .VisualAppearance.Add(1,"gBFLBCJwBAEHhEJAAEhIDhAxHAxg0HG0Mg4xGI3HMOig3GcJiYAf8jAEhhUnAAyhEqg8hk0oAsIjgAiAwmYxGA4mYzGwwkI0i0ooUnB0IBMIl1Dg8zmYyGolptPkI1m" & _ "Y1GAll9KoUslNIrVCqNQldShFUstXAVfrVcrlZtVhuFnsUHq1zoczoQGhFBkNpg6zbDykUkhsPHE2h85nc9n8xtVDtlex9Msd2p1YstVq9ux8HyMtzuFz1PsNTzQlv2h" & _ "hWfkuqpeVuN0q+nvEooN5veSAGpkb/ACcZrvhU3w83nM/poxGuchGpoVBvWgg+8knA4WimnFxI45Er5XOlHMg/Q3XU33W4ew9Wyu11mchDagcO7zus8VDoNBBEIKBpMY" & _ "6DqOQyokhA/IQIQmwMk4bIQFDcoO6LWgwhQkNcABwEyAB5GwWbet6cRQg3DENQ5D8QxADZvEkAB8nabsURGeBpFM3pwE2AEZRpDx/neZpOR3Dz9oO/r/wCMoZNTBQAQR" & _ "JSEwYg8HPGhEIoNCaEwq10gQ2WcRt7LcRxRFpuxUAEURQ3sczBEMgTTG8gN7HpOSEAEiQBAQZpmQ0DibPUFwbKcHwkhQoQtNQNzNEMbABOKDy/DMYQzHLeoPL0OTJSUd" & _ "0pHcxTewk5zrIygIRPslz4lEngBKIAQivgASs/kLSBTlO00f8t0vGcgUbDlDRjXLCUNRERRvRgAHW2oAICA==") With .Columns.Add("Default") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox,True) .PartialCheck = True End With With .Columns.Add("Position") .FormatColumn = "1 rindex ``" .Visible = False End With With .ConditionalFormats.Add("%C1 mod 2") .BackColor32 = &H1000000 End With With .Items .AddItem("Item 1") .AddItem("Item 2") .AddItem("Item 3") .AddItem("Item 4") End With .EndUpdate() End With |
2033 |
How can I specify alternate background colors for each root item, similar with BackColorAlternate
Dim h With Exg2antt1 .BeginUpdate() .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot With .Columns.Add("Default") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellHasCheckBox,True) .PartialCheck = True End With With .Columns.Add("Position") .FormatColumn = "( ( 1:=( ( 0:=(1 rpos '') ) lfind `.`) ) < 0 ? =:0 : (=:0 left =:1) )" .Visible = False End With With .ConditionalFormats.Add("%C1 mod 2") .BackColor = Color.FromArgb(240,240,240) End With With .Items h = .AddItem("Root 1") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") .set_ExpandItem(h,True) h = .AddItem("Root 2") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") h = .AddItem("Root 3") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") End With .EndUpdate() End With |
2032 |
How can I change the visual appearance of the +/- buttons, open/close glyphs as current visual theme (method 4)
Dim h With Exg2antt1 .BeginUpdate() .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot .VisualDesign = "gBFLBWIgBAEHhEJAEGg6VAkHeLpgwChAOhULB8XAUUg8MAAREEHGMcgRCJ0ei8dhABDEcQAAYAQGKIYBkAKBQAGaAoDDMOQwQwAAxjGKEEwsACEIrjKCRShyCYZRhGc" & _ "TSBCIZBqEqSZLiEZRQiiCYsS5GQBRWAkEwiBiEQTjea5CgOIAFS7LIqjRQEBxhIaZYIGaiQADENo9TxIMZAfBIHShK6NJABCCSQKkYx0HScRijDIEFwGIQmbKiej4DCi" & _ "CQQW7OYYRVCNMQSfa8HivJyrcamfp/YBgOBYHb1eLVPR5LwfPCGUw1P6PLxkORZHimK4tSLHV7xVpMIwZFafIQhCCoHomS5NU7UNR0TQUFx9FaGX7rDDsGwLAJ6XRgF4" & _ "bg2VpnHePpenAN4bH2GwHFmApSjEGBLnWOpRGOTBZHOegrE6BxPiWVJqCweQrn0LgJAWJBjwgaw1gKO5HmWch5h+fovF+G5bmich4BgfZkB8dynRUVYqiUR5rnmex/F6" & _ "N4tn2AJfnebZ3DEXw3HWXgzAyIwgicKJKBKEIhCeCgiHyHYFEmSAFmqBghFIdgSCeIJygYDAyAgJx6AoIINAMOJNCgCZCGoGoLmMCI+CwJoihMNglCCIhzFCUg0EmMhg" & _ "hWDBkAiQg9CUY4jEYN4Jk2IxklYJoJHIUg+CSZJSESFwkkkGI+FOFIJEIRhPhMCRJCSVoRrSBhiDgTZjHYT4PEkYhwhgJYm0SaIaiaSYuE+GQNlmCIBGCJxjhiZQ5AkM" & _ "hAg6ExJCkPhPguaAiFYUAlAkKZ0g6HoOEmWR/GHcA4m0OwIlIJIHCRgQshGJhpjoaocieaZiC6GAimkUgehIOwnGYGYIGkah6jaE4rg6SpCjKK5rEOMYlGIGIihKOggl" & _ "oFoqj6L5aGaBo6CkGIkAQjiPpCAAaJILCTJQlKPACDaXJgmSaJsnCdJ4nygKEoijKQpSmKcqCpKoqysK0rivLAsSyLMtC1LYty4Lkui7LwvS+L8wDBMIwzEMUxjHMgyT" & _ "KMszDNM4zzQNE0jTNQ1TWNc2DZNo2zcN03jfOA4TiOM5DlOY5zoOk6jrOw7TuO88DxPI8z0PU9j3Pg+T6Ps/D9P4/0AQFAkDQRBUGQdCEJQpC0MQ1DkPRBEUSRNFEVBh" & _ "FkXRhGQ9D6Dxfh+W5gGGd4QH2XQjCmDpFFaKoVB+D5Xmed5+H8YAHnIAh9EwV5Fl0d4MkMKJICmSgygSJAoEmMUCIPgnDCCIOQFYCxJjwFoCcA4kxoF+AIJkAgExegDE" & _ "gEYQInAzCUAIOEGgfxiiRDYF1Q4EQ2BSCaEQYwbAiKREMpRSymFNDIAkAxT6oVRgSA2qdVKq1WqvVirMZQUhSCnBUMoIgoQRgnGSIQUgkg1hIHYAkAYMROAmHiLsE4xx" & _ "SCxBwEwCQ0wmDdBsE0GYXBtg2CSPMFIuwYiQBYBQeAcwOCnBCCZgw0g0glBONAQgqQThCGgPQGoBQfiRGmOEZIPAXjsBoPAO4HRThhA0EQSA5BAgaCKJIGg3QdhOCmNU" & _ "BoQAijTCIF0FwQxpCHDIPAYYMQGgtCmFcaQtRAjZCyFYSojQ2B2BoKwIYFApBXEIBsIQ1QsAWAWEwaA1xCgjAoIAQBAQ=" .Columns.Add("Column") With .Items h = .AddItem("Root 1") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") .set_ExpandItem(h,True) h = .AddItem("Root 2") .InsertItem(h,Nothing,"Child") End With .EndUpdate() End With |
2031 |
How can I change the visual appearance of the +/- buttons, open/close glyphs as current visual theme (method 3)
Dim h With Exg2antt1 .BeginUpdate() With .VisualAppearance .Add(3,"gBFLBCJwBAEHhEJAAEhABDwCg6AADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJ5BhIAAyDSJMjSRJUEhqGCWYDleYYYAKHIMQLJQKQS" & _ "BcQR9EaBZBAWTpQC0OJDTJRI4TNAgbSYAAYRqoCb6loTKypaxjCQQIgkUBpGKdBynEYsDwSGyJCCJWyIbpKAwoVbcs4AYhuJpaQi+d5PFbjVT8dLAMBwLA8EwXAJ+Opf" & _ "DxXU7eFKpR5fchXTI8UxXFqXZhkeQrfh7KYVRBKdBQRBEFQPJqnahqOpaXo2RoLUJKcQwHTmHYNQTALyuTALZrWeZ3XrgN74LbtZzVQauYRpbCMEr6bpoWLnFi6Ho1U4" & _ "llWah1jqSweFqfxPgQQRphi+Yak0YIuqUfJegef4zluaJ3nqPJeCYH4BAeX5TDLBpVGqKRRnwf4flefZtHsX54BYAR/F+EwVnUd5eAMMJKDIChygyIQpAoEh4iIJ5Jlg" & _ "XIcgCXpIGoFwnGEQh6BEKBgmMIICHgIJCAiUAzgyUoAhwJohkiRgygwYpiGoKwzGIcgKCkNQNCMRIbCYCRYk4QoMiOchWDwNBjhiJJaDYTRiGiFwlCQAhOE8JBJHITIR" & _ "gwZRZFCFCZBkOIUhKTRpCWAwgGYQ4El4NxlBifIWCcCYCFoaoMGaKYyG6GxlBmGJdhkCAWBIeA5g4U4QhMJAImkPIShRVxGgQJRlCIUISh+SJpnCZIeBgFgiHgO4OlOM" & _ "INCISByECDQikkGhuh2JwpmqBogCKaYiC6FwhmkQ4yHgYgYiaHopiuaRakCbIsisSpGjYOwaHYKYMCkK5CA2IxrCwCwFigaJrkLTI6lcdANAEgIA=") .Add(1,"CP:3 -2 -2 2 2") .Add(4,"gBFLBCJwBAEHhEJAAEhABEICg6AADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJ5BhIAAyDSJMjSRJUEhqGCWYDleYYYAKHIMQLJQKQS" & _ "BcQR9EaBZBAWTpQC0OJDTJRI4TNAgbSYAAYRqoCb6loTKypaxjCQQIgkUBpGKdBynEYsDwSGyJCCJWyIbpKAwoVbcs4AYhuJpaQi+d5PFbjVT8dLAMBwLA8EwXAJ+Opf" & _ "DxXU7eFKpR5fchXTI8UxXFqXZhkeQrfh7KYVRBKdBQRBEFQPJqnahqOpaXo2RoLUJKcQwHTmHYNQTALyuTALZrWeZ3XrgN74LbtZzVQauYRpbCMEr6bpoWLnFi6Ho1U4" & _ "llWah1jqSweFqfxPgQQRphi+Yak0YIuqUfJeg8X4rluaZ3niGB+AQHx/EyShjjEVYqiUR5rnmex/GAB5+AIf4gEeXJFHyXZ3gCTAygyAociMKBKEKBIeCiCZyHYFAnCE" & _ "eBkh+BghFgRIegOCgYCySAgh4CAkgINAMmMNIgCcCYjn4LoLmMCJGDKC5ijIagoDMYhCAoJg1A0IxEhsJgJFiThChCY5yFYPA0GOGIYloNhNGIaIXCUJACE4TwkEkchO" & _ "FSFYlFkXhUCUCQZEYTglCSMxaEkYJIBmFJhDeDZZEYPwlgmQhghaGqVDoa4bGaeY6FGGZNlmFIBGEJ4jhiZQ5AkMhAg6E5JCkRoGCUSQ6B6CYiSCBIOh+DhJmmARiWQO" & _ "JtDsCJSCSBwkXSLIRicaZ6HqIIomoIguhwIpphIHoWDsJ4mCGChpmqOpGheLIOkqUo2iya4DjGJxihiQoSj4IJaDaMpCjCWoGg6PgpBiQ4tHcQJQBAgI=") .Add(2,"CP:4 -2 -2 2 2") End With .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exGroupLinesAtRoot .HasButtons = exontrol.EXG2ANTTLib.ExpandButtonEnum.exCustom .set_HasButtonsCustom(False,16777216) .set_HasButtonsCustom(True,33554432) .Columns.Add("Column") With .Items h = .AddItem("Root 1") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") .set_ExpandItem(h,True) h = .AddItem("Root 2") .InsertItem(h,Nothing,"Child") End With .EndUpdate() End With |
2030 |
How can I change the visual appearance of the +/- buttons, open/close glyphs as current visual theme (method 2)
Dim h With Exg2antt1 .BeginUpdate() With .VisualAppearance .Add(1,"XP:TREEVIEW 2 1") .Add(2,"XP:TREEVIEW 2 2") End With .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exTreeGlyphOpen,&H1000000) .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exTreeGlyphClose,&H2000000) .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot .Columns.Add("Column") With .Items h = .AddItem("Root 1") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") .set_ExpandItem(h,True) h = .AddItem("Root 2") .InsertItem(h,Nothing,"Child") End With .EndUpdate() End With |
2029 |
How can I find if the control is running in DPI mode
With Exg2antt1 Debug.Print( .FormatABC("dpi = 1 ? `normal/stretch mode` : `dpi mode`") ) End With |
2028 |
How can I change the visual appearance of the +/- buttons (method 1)
Dim h With Exg2antt1 .BeginUpdate() With .VisualAppearance .Add(1,"gBFLBCJwBAEHhEJAAEhABDwCg6AADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJ5BhIAAyDSJMjSRJUEhqGCWYDleYYYAKHIMQLJQKQS" & _ "BcQR9EaBZBAWTpQC0OJDTJRI4TNAgbSYAAYRqoCb6loTKypaxjCQQIgkUBpGKdBynEYsDwSGyJCCJWyIbpKAwoVbcs4AYhuJpaQi+d5PFbjVT8dLAMBwLA8EwXAJ+Opf" & _ "DxXU7eFKpR5fchXTI8UxXFqXZhkeQrfh7KYVRBKdBQRBEFQPJqnahqOpaXo2RoLUJKcQwHTmHYNQTALyuTALZrWeZ3XrgN74LbtZzVQauYRpbCMEr6bpoWLnFi6Ho1U4" & _ "llWah1jqSweFqfxPgQQRphi+Yak0YIuqUfJegef4zluaJ3nqPJeCYH4BAeX5TDLBpVGqKRRnwf4flefZtHsX54BYAR/F+EwVnUd5eAMMJKDIChygyIQpAoEh4iIJ5Jlg" & _ "XIcgCXpIGoFwnGEQh6BEKBgmMIICHgIJCAiUAzgyUoAhwJohkiRgygwYpiGoKwzGIcgKCkNQNCMRIbCYCRYk4QoMiOchWDwNBjhiJJaDYTRiGiFwlCQAhOE8JBJHITIR" & _ "gwZRZFCFCZBkOIUhKTRpCWAwgGYQ4El4NxlBifIWCcCYCFoaoMGaKYyG6GxlBmGJdhkCAWBIeA5g4U4QhMJAImkPIShRVxGgQJRlCIUISh+SJpnCZIeBgFgiHgO4OlOM" & _ "INCISByECDQikkGhuh2JwpmqBogCKaYiC6FwhmkQ4yHgYgYiaHopiuaRakCbIsisSpGjYOwaHYKYMCkK5CA2IxrCwCwFigaJrkLTI6lcdANAEgIA=") .Add(2,"gBFLBCJwBAEHhEJAAEhABEICg6AADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJ5BhIAAyDSJMjSRJUEhqGCWYDleYYYAKHIMQLJQKQS" & _ "BcQR9EaBZBAWTpQC0OJDTJRI4TNAgbSYAAYRqoCb6loTKypaxjCQQIgkUBpGKdBynEYsDwSGyJCCJWyIbpKAwoVbcs4AYhuJpaQi+d5PFbjVT8dLAMBwLA8EwXAJ+Opf" & _ "DxXU7eFKpR5fchXTI8UxXFqXZhkeQrfh7KYVRBKdBQRBEFQPJqnahqOpaXo2RoLUJKcQwHTmHYNQTALyuTALZrWeZ3XrgN74LbtZzVQauYRpbCMEr6bpoWLnFi6Ho1U4" & _ "llWah1jqSweFqfxPgQQRphi+Yak0YIuqUfJeg8X4rluaZ3niGB+AQHx/EyShjjEVYqiUR5rnmex/GAB5+AIf4gEeXJFHyXZ3gCTAygyAociMKBKEKBIeCiCZyHYFAnCE" & _ "eBkh+BghFgRIegOCgYCySAgh4CAkgINAMmMNIgCcCYjn4LoLmMCJGDKC5ijIagoDMYhCAoJg1A0IxEhsJgJFiThChCY5yFYPA0GOGIYloNhNGIaIXCUJACE4TwkEkchO" & _ "FSFYlFkXhUCUCQZEYTglCSMxaEkYJIBmFJhDeDZZEYPwlgmQhghaGqVDoa4bGaeY6FGGZNlmFIBGEJ4jhiZQ5AkMhAg6E5JCkRoGCUSQ6B6CYiSCBIOh+DhJmmARiWQO" & _ "JtDsCJSCSBwkXSLIRicaZ6HqIIomoIguhwIpphIHoWDsJ4mCGChpmqOpGheLIOkqUo2iya4DjGJxihiQoSj4IJaDaMpCjCWoGg6PgpBiQ4tHcQJQBAgI=") End With .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exTreeGlyphOpen,&H1000000) .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exTreeGlyphClose,&H2000000) .Columns.Add("Column") With .Items h = .AddItem("Root 1") .InsertItem(h,Nothing,"Child 1") .InsertItem(h,Nothing,"Child 2") .set_ExpandItem(h,True) h = .AddItem("Root 2") .InsertItem(h,Nothing,"Child") End With .EndUpdate() End With |
2027 |
How can I add a summary bar once the user group by a column
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem Dim l With Exg2antt1 With .Items .set_ItemDividerLine(Item,exontrol.EXG2ANTTLib.DividerLineEnum.EmptyLine) .AddBar(Item,"Summary",#12/2/2017#,#12/2/2017#) .DefineSummaryBars(Item,"",-3,"") l = .get_GroupItem(Item) .set_CellSingleLine(Item,l,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) .set_CellBold(Item,l,True) .set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With .Chart.set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/10/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() .VisualAppearance.Add(1,"gBFLBCJwBAEHhEJAAEhABOUGACAADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJwFgmEgADCMQwAFBIbhrE4ZBjHGQRUgyI43RhHUBzV" & _ "IUBxDEaTZLlEYJBgeHYhDJPcaUVDcWQHGyeZwjSgpKoWSJIU5NcggPDgEwTKCmKlTAKoSzJMyEmwWRAdVTZLSEaxierKPhyWT/XgAF4PfDFKRXFqXY5mKZJFqKOI8TxI" & _ "NgxPQMGyrBqraLqKwQGrGCQKSBhUZ3dS2JR3OSlYRuQAMVgOXoDZhPWZXbDtSzPE63NgtOR5DiGWalABoeoxRa9cz3ViCJSrGTqIoINIzZLHFQbPpdAYdP6BeIjXhhZx" & _ "BBuLZXmEOh9CcNoni2N4MjWVodh+DpfBeLJinsWR9AyYwVAkGBhEAFphGiRogDEGBamkFgtjcZgHiMbgehYaQhAIEIREAaQYkcQZUHIGRUGQDBOEaBAhDYDxGkMZAkCg" & _ "eoagYZAYEYAYIAWGhemICIFj8WIiCiFR5gkIhogmBoKGKJx2C6C5hniMgggqYwog0UoNGMZJiDiCZRgOLY0ECUAQICA==") With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,342) With .Bars.Item("Summary") .StartShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .EndShape = exontrol.EXG2ANTTLib.ShapeCornerEnum.exShapeIconEmpty .Shape = exontrol.EXG2ANTTLib.ShapeBarEnum.exShapeSolid .Color32 = &H1000000 .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%513%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With End With With .Columns .Add("C1") .Add("C2") .Add("C3") With .Add("Pos") .FormatColumn = "1 pos ``" .AllowGroupBy = False .Position = 0 .Width = 48 .AllowSizing = False End With End With .SortBarVisible = True .SortBarCaption = "Drag a <b>column</b> header here to group by that column." .AllowGroupBy = True .HasLines = exontrol.EXG2ANTTLib.HierarchyLineEnum.exNoLine .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exNoLinesAtRoot With .Items h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") End With With .Columns.Item(0) .SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending End With .EndUpdate() End With |
2026 |
Is it possible to display no +/- button for grouped items
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem Dim l With Exg2antt1 With .Items .set_ItemDividerLine(Item,exontrol.EXG2ANTTLib.DividerLineEnum.EmptyLine) .AddBar(Item,"Progress",#12/2/2017#,#12/2/2017#) .DefineSummaryBars(Item,"",-3,"") l = .get_GroupItem(Item) .set_CellSingleLine(Item,l,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) .set_CellBold(Item,l,True) .set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With .Chart.set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/10/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,342) End With With .Columns .Add("C1") .Add("C2") .Add("C3") With .Add("Pos") .FormatColumn = "1 pos ``" .AllowGroupBy = False .Position = 0 .Width = 48 .AllowSizing = False End With End With .SortBarVisible = True .SortBarCaption = "Drag a <b>column</b> header here to group by that column." .AllowGroupBy = True .HasLines = exontrol.EXG2ANTTLib.HierarchyLineEnum.exNoLine .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exNoLinesAtRoot With .Items h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") End With With .Columns.Item(0) .SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .Alignment = exontrol.EXG2ANTTLib.AlignmentEnum.CenterAlignment .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellBackColor,15790320) End With .EndUpdate() End With |
2025 |
How can I change the label, caption or the formula of the grouped items
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem With Exg2antt1 With .Items .AddBar(Item,"Progress",#12/2/2017#,#12/2/2017#) .DefineSummaryBars(Item,"",-3,"") End With End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/10/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,342) End With With .Columns With .Add("C1") .GroupByTotalField = "" .GroupByFormatCell = "upper(value)" End With .Add("C2") .Add("C3") With .Add("Pos") .FormatColumn = "1 pos ``" .AllowGroupBy = False .Position = 0 .Width = 48 .AllowSizing = False End With End With .SortBarVisible = True .SortBarCaption = "Drag a <b>column</b> header here to group by that column." .AllowGroupBy = True With .Items h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") End With .Columns.Item(0).SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .EndUpdate() End With |
2024 |
How can I change the aspect of grouped items
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem Dim l With Exg2antt1 With .Items .set_ItemDividerLine(Item,exontrol.EXG2ANTTLib.DividerLineEnum.EmptyLine) .AddBar(Item,"Progress",#12/2/2017#,#12/2/2017#) .DefineSummaryBars(Item,"",-3,"") l = .get_GroupItem(Item) .set_CellSingleLine(Item,l,exontrol.EXG2ANTTLib.CellSingleLineEnum.exCaptionWordWrap) .set_CellBold(Item,l,True) .set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With .Chart.set_ItemBackColor(Item,Color.FromArgb(190,190,190)) End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/10/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,342) End With With .Columns .Add("C1") .Add("C2") .Add("C3") With .Add("Pos") .FormatColumn = "1 pos ``" .AllowGroupBy = False .Position = 0 .Width = 48 .AllowSizing = False End With End With .SortBarVisible = True .SortBarCaption = "Drag a <b>column</b> header here to group by that column." .AllowGroupBy = True With .Items h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") End With .Columns.Item(0).SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .EndUpdate() End With |
2023 |
How can I collapse all items when the user performs a grouping
' AddGroupItem event - Occurs after a new Group Item has been inserted to Items collection. Private Sub Exg2antt1_AddGroupItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddGroupItem With Exg2antt1 With .Items .set_ExpandItem(Item,False) .set_ItemDividerLine(Item,exontrol.EXG2ANTTLib.DividerLineEnum.EmptyLine) .AddBar(Item,"Progress",#12/2/2017#,#12/2/2017#) .DefineSummaryBars(Item,"",-3,"") End With End With End Sub ' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/10/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,342) End With With .Columns .Add("C1") .Add("C2") .Add("C3") With .Add("Pos") .FormatColumn = "1 pos ``" .AllowGroupBy = False .Position = 0 .Width = 48 .AllowSizing = False End With End With .SortBarVisible = True .SortBarCaption = "Drag a <b>column</b> header here to group by that column." .AllowGroupBy = True With .Items h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") End With .Columns.Item(0).SortOrder = exontrol.EXG2ANTTLib.SortOrderEnum.SortAscending .EndUpdate() End With |
2022 |
Is it possible to select columns that user can drop to the sort bar, when using the Group By feature
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/10/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,342) End With With .Columns .Add("C1") .Add("C2") .Add("C3") With .Add("Pos") .FormatColumn = "1 pos ``" .AllowGroupBy = False .Position = 0 .Width = 48 .AllowSizing = False End With End With .SortBarVisible = True .SortBarCaption = "<fgcolor=FF0000>Try to drag the Pos column here." .AllowGroupBy = True With .Items h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item A") .set_CellValue(h,1,"SubItem A.1") .set_CellValue(h,2,"SubItem A.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") h = .AddItem("Item B") .set_CellValue(h,1,"SubItem B.1") .set_CellValue(h,2,"SubItem B.2") End With .EndUpdate() End With |
2021 |
How can I filter for the type of the bars I have in my chart
With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #11/28/2017# .set_PaneWidth(False,0) With .Bars.Item("Task") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%0%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) End With With .Bars.Copy("Task","GTask") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%0%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) .Color = Color.FromArgb(0,255,0) End With With .Bars.Copy("Task","RTask") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarCaption,"<%=%0%>") .set_Def(exontrol.EXG2ANTTLib.ItemBarPropertyEnum.exBarHAlignCaption,18) .Color = Color.FromArgb(255,0,0) End With .ColumnsFormatLevel = "0" End With .OnResizeControl = exontrol.EXG2ANTTLib.OnResizeControlEnum.exDisableSplitter Or exontrol.EXG2ANTTLib.OnResizeControlEnum.exResizeChart With .Columns.Add("Default") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Type") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarKey,"") .set_Def(exontrol.EXG2ANTTLib.DefColumnEnum.exCellValueToItemBarProperty,0) .Visible = False .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Items .AllowCellValueToItemBar = True .AddBar(.AddItem("Item 1"),"Task",#12/4/2017#,#12/12/2017#) .AddBar(.AddItem("Item 2"),"GTask",#12/4/2017#,#12/12/2017#) .AddBar(.AddItem("Item 3"),"RTask",#12/4/2017#,#12/12/2017#) .AddBar(.AddItem("Item 4"),"Task",#12/4/2017#,#12/12/2017#) .AddBar(.AddItem("Item 5"),"GTask",#12/4/2017#,#12/12/2017#) .AddBar(.AddItem("Item 6"),"RTask",#12/4/2017#,#12/12/2017#) End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "(( ( all replace `[<b>` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replace `</b>]` with ` </b></bgcolor></fgcolor>` replace `[" & _ "<s>` with `<bgcolor=C0C0C0><fgcolor=FFFFFF> ` replace `</s>]` with ` </fgcolor></bgcolor>` ) + `<r><fgcolor=808080>` + ( matchi" & _ "temcount < 0 ? ( ( len(value) ? `` : `` ) + `<r>` + abs(matchitemcount + 1) + ` result(s)` ) : (`<r><fgcolor=808080>`+ itemcount" & _ " + ` item(s)`) )))" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCompact Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarShowCloseIfRequired Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarSingleLine Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(1) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "GTask|RTask" End With .ApplyFilter() .EndUpdate() End With |
2020 |
How can I display the control's filter bar in the Items section only, as it was displayed before
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") .set_CellValue(.AddItem("Item B"),1,"Sub-Item B") .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarShort With .Columns.Item(1) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exPattern .Filter = "*B" End With .ApplyFilter() .EndUpdate() End With |
2019 |
FilterBarCaption ALL Keyword ( sample 2, result )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 i = .FormatABC("value + 1",.Items.get_ItemToIndex(Item)) .Items.set_CellImage(Item,3,i) .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Check") With .Editor .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.CheckValueType .set_Option(exontrol.EXG2ANTTLib.EditorOptionEnum.exCheckValue2,1) End With .DisplayFilterButton = True .DisplayFilterPattern = False .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exCheck End With With .Columns.Add("Image") .DisplayFilterButton = True .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exImage .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") h = .AddItem("Item B") .set_CellValue(h,1,"Sub-Item B") .set_CellState(h,2,1) .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "(( ( all replace `[<b>` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replace `</b>]` with ` </b></bgcolor></fgcolor>` replace `[" & _ "<s>` with `<bgcolor=C0C0C0><fgcolor=FFFFFF> ` replace `</s>]` with ` </fgcolor></bgcolor>` ) + `<r><fgcolor=808080>` + ( matchi" & _ "temcount < 0 ? ( ( len(value) ? `` : `` ) + `<r>` + abs(matchitemcount + 1) + ` result(s)` ) : (`<r><fgcolor=808080>`+ itemcount" & _ " + ` item(s)`) )))" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .Columns.Item(2).Filter = 1 .ApplyFilter() .EndUpdate() End With |
2018 |
FilterBarCaption ALL Keyword ( sample 1 )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 i = .FormatABC("value + 1",.Items.get_ItemToIndex(Item)) .Items.set_CellImage(Item,3,i) .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Check") With .Editor .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.CheckValueType .set_Option(exontrol.EXG2ANTTLib.EditorOptionEnum.exCheckValue2,1) End With .DisplayFilterButton = True .DisplayFilterPattern = False .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exCheck End With With .Columns.Add("Image") .DisplayFilterButton = True .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exImage .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") h = .AddItem("Item B") .set_CellValue(h,1,"Sub-Item B") .set_CellState(h,2,1) .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "all" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .Columns.Item(2).Filter = 1 .ApplyFilter() .EndUpdate() End With |
2017 |
FilterBarCaption ALLUI Keyword ( sample 2, result )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 i = .FormatABC("value + 1",.Items.get_ItemToIndex(Item)) .Items.set_CellImage(Item,3,i) .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Check") With .Editor .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.CheckValueType .set_Option(exontrol.EXG2ANTTLib.EditorOptionEnum.exCheckValue2,1) End With .DisplayFilterButton = True .DisplayFilterPattern = False .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exCheck End With With .Columns.Add("Image") .DisplayFilterButton = True .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exImage .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") h = .AddItem("Item B") .set_CellValue(h,1,"Sub-Item B") .set_CellState(h,2,1) .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "(( ( allui replace `[<b>` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replace `</b>]` with ` </b></bgcolor></fgcolor>` replace " & _ "`[<s>` with `<bgcolor=C0C0C0><fgcolor=FFFFFF> ` replace `</s>]` with ` </fgcolor></bgcolor>` ) + `<r><fgcolor=808080>` + ( matc" & _ "hitemcount < 0 ? ( ( len(value) ? `` : `` ) + `<r>` + abs(matchitemcount + 1) + ` result(s)` ) : (`<r><fgcolor=808080>`+ itemcou" & _ "nt + ` item(s)`) )))" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .Columns.Item(2).Filter = 1 .ApplyFilter() .EndUpdate() End With |
2016 |
FilterBarCaption ALLUI Keyword ( sample 1 )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 i = .FormatABC("value + 1",.Items.get_ItemToIndex(Item)) .Items.set_CellImage(Item,3,i) .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Check") With .Editor .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.CheckValueType .set_Option(exontrol.EXG2ANTTLib.EditorOptionEnum.exCheckValue2,1) End With .DisplayFilterButton = True .DisplayFilterPattern = False .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exCheck End With With .Columns.Add("Image") .DisplayFilterButton = True .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exImage .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") h = .AddItem("Item B") .set_CellValue(h,1,"Sub-Item B") .set_CellState(h,2,1) .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "allui" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .Columns.Item(2).Filter = 1 .ApplyFilter() .EndUpdate() End With |
2015 |
FilterBarCaption AVAILABLE Keyword ( sample 2, result )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 i = .FormatABC("value + 1",.Items.get_ItemToIndex(Item)) .Items.set_CellImage(Item,3,i) .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Check") With .Editor .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.CheckValueType .set_Option(exontrol.EXG2ANTTLib.EditorOptionEnum.exCheckValue2,1) End With .DisplayFilterButton = True .DisplayFilterPattern = False .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exCheck End With With .Columns.Add("Image") .DisplayFilterButton = True .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exImage .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") h = .AddItem("Item B") .set_CellValue(h,1,"Sub-Item B") .set_CellState(h,2,1) .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "(( ( value replace `[` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replace `]` with ` </b></bgcolor></fgcolor>` ) + ` ` + ( ava" & _ "ilable replace `[` with `<bgcolor=C0C0C0><fgcolor=FFFFFF><b> ` replace `]` with ` </b></bgcolor></fgcolor>` replace `<s>` with `" & _ "` replace `</s>` with `` ) + `<fgcolor=808080>` + ( matchitemcount < 0 ? ( ( len(value) ? `` : `` ) + `<r>` + abs(matchitemcount" & _ " + 1) + ` result(s)` ) : (`<r><fgcolor=808080>`+ itemcount + ` item(s)`) )))" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .Columns.Item(2).Filter = 1 .ApplyFilter() .EndUpdate() End With |
2014 |
FilterBarCaption AVAILABLE Keyword ( sample 1 )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem Dim i With Exg2antt1 i = .FormatABC("value + 1",.Items.get_ItemToIndex(Item)) .Items.set_CellImage(Item,3,i) .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Images("gBJJgBAIDAAGAAEAAQhYAf8Pf4hh0QihCJo2AEZjQAjEZFEaIEaEEaAIAkcbk0olUrlktl0vmExmUzmk1m03nE5nU7nk9n0/oFBoVDolFo1HpFJpVLplNp1PqFRqVTq" & _ "lVq1XrFZrVbrldr1fsFhsVjslls1ntFptVrtltt1vuFxuVzul1u13vF5vV7vl9v1/wGBwWDwmFw2HxGJxWLxmNx0xiFdyOTh8Tf9ZymXx+QytcyNgz8r0OblWjyWds+m" & _ "0ka1Vf1ta1+r1mos2xrG2xeZ0+a0W0qOx3GO4NV3WeyvD2XJ5XL5nN51aiw+lfSj0gkUkAEllHanHI5j/cHg8EZf7w8vl8j4f/qfEZeB09/vjLAB30+kZQAP/P5/H6/y" & _ "NAOAEAwCjMBwFAEDwJBMDwLBYAP2/8Hv8/gAGAD8LQs9w/nhDY/oygIA=") With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Check") With .Editor .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.CheckValueType .set_Option(exontrol.EXG2ANTTLib.EditorOptionEnum.exCheckValue2,1) End With .DisplayFilterButton = True .DisplayFilterPattern = False .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exCheck End With With .Columns.Add("Image") .DisplayFilterButton = True .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exImage .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") h = .AddItem("Item B") .set_CellValue(h,1,"Sub-Item B") .set_CellState(h,2,1) .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080> ` + value + ` </fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "value + ` ` + available" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .Columns.Item(2).Filter = 1 .ApplyFilter() .EndUpdate() End With |
2013 |
Is it possible to somehow highlight the column's name different than its filter value in the control's filter bar ( sample 3, results )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") .set_CellValue(.AddItem("Item B"),1,"Sub-Item B") .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080>` + value + `</fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "(`<b>` + value + `</b><fgcolor=808080>` + ( matchitemcount < 0 ? ( ( len(value) ? `` : `` ) + `<r>` + abs(matchitemcount + 1) +" & _ " ` result(s)` ) : (`<fgcolor=808080>`+ itemcount + ` item(s)`) )) replace `[` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replac" & _ "e `]` with ` </b></bgcolor></fgcolor>`" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarToggle With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With With .Columns.Item(1) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exPattern .Filter = "*B" End With .ApplyFilter() .EndUpdate() End With |
2012 |
Is it possible to somehow highlight the column's name different than its filter value in the control's filter bar ( sample 2 )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") .set_CellValue(.AddItem("Item B"),1,"Sub-Item B") .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .FilterBarFont = .Font .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080>` + value + `</fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "value replace `[` with `<bgcolor=000000><fgcolor=FFFFFF><b> ` replace `]` with ` </b></bgcolor></fgcolor>`" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarToggle With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With With .Columns.Item(1) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exPattern .Filter = "*B" End With .ApplyFilter() .EndUpdate() End With |
2011 |
Is it possible to somehow highlight the column's name different than its filter value in the control's filter bar ( sample 1 )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With With .Columns.Add("Col-1") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Col-2") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .set_CellValue(.AddItem("Item A"),1,"Sub-Item A") .set_CellValue(.AddItem("Item B"),1,"Sub-Item B") .set_CellValue(.AddItem("Item C"),1,"Sub-Item C") End With .set_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd,.FormatABC("`<fgcolor=808080>` + value + `</fgcolor>`",.get_Description(exontrol.EXG2ANTTLib.DescriptionTypeEnum.exFilterBarAnd))) .FilterBarCaption = "value replace `[` with `<fgcolor=808080>[` replace `]` with `]</fgcolor>`" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarToggle With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With With .Columns.Item(1) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exPattern .Filter = "*B" End With .ApplyFilter() .EndUpdate() End With |
2010 |
Is it possible to automatically displays the control's filter label to the right
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With With .Columns.Add("Item") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarCaption = "`<r>` + value" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarShowCloseOnRight Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarToggle With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item B" End With .ApplyFilter() .EndUpdate() End With |
2009 |
How can I get the number of results/items being shown in the control's filter bar (sample 4)
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With With .Columns.Add("Item") .DisplayFilterButton = True .FilterList = exontrol.EXG2ANTTLib.FilterListEnum.exShowExclude Or exontrol.EXG2ANTTLib.FilterListEnum.exShowFocusItem Or exontrol.EXG2ANTTLib.FilterListEnum.exShowCheckBox Or exontrol.EXG2ANTTLib.FilterListEnum.exSortItemsAsc End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarFont = .Font .FilterBarPrompt = .FormatABC("`<b>` + value",.FilterBarPrompt) .FilterBarCaption = "`<b><r>` + value + `</b><fgcolor=808080>` + ( matchitemcount < 0 ? ( ( len(value) ? `<br>` : `` ) + `<r>` + abs(matchitemcount " & _ "+ 1) + ` result(s)` ) : (`<fgcolor=808080>`+ itemcount + ` item(s)`) )" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCompact Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarShowCloseOnRight Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarShowCloseIfRequired Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCaptionVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible .EndUpdate() End With |
2008 |
How can I get the number of results being shown in the control's filter bar (sample 3)
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Columns.Add("Item").DisplayFilterButton = True With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarFont = .Font .FilterBarCaption = "`<b><r>` + value + `</b><fgcolor=808080>` + ( matchitemcount < 0 ? ( ( len(value) ? `<br>` : `` ) + `<r>` + abs(matchitemcount " & _ "+ 1) + ` result(s)` ) : ``)" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCompact Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCaptionVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .ApplyFilter() .EndUpdate() End With |
2007 |
How can I get the number of results being shown in the control's filter bar (sample 2, compact)
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Columns.Add("Item").DisplayFilterButton = True With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarFont = .Font .FilterBarCaption = "`<b><r>` + value + `</b><fgcolor=808080>` + ( matchitemcount < 0 ? `<off -4> ` + abs(matchitemcount + 1) + ` result(s)` : ``)" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCompact Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarSingleLine Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCaptionVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .ApplyFilter() .EndUpdate() End With |
2006 |
How can I get the number of results being shown in the control's filter bar (sample 1)
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Columns.Add("Item").DisplayFilterButton = True With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarFont = .Font .FilterBarCaption = "`<b>` + value + `</b><r><fgcolor=808080>` + ( matchitemcount < 0 ? abs(matchitemcount + 1) + ` result(s)` : ``)" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCaptionVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .ApplyFilter() .EndUpdate() End With |
2005 |
FilterBarCaption Predefined Keywords
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub ' AfterExpandItem event - Fired after an item is expanded (collapsed). Private Sub Exg2antt1_AfterExpandItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AfterExpandItem With Exg2antt1 .Refresh() End With End Sub Dim h With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .LinesAtRoot = exontrol.EXG2ANTTLib.LinesAtRootEnum.exLinesAtRoot .Columns.Add("Item").DisplayFilterButton = True With .Columns.Add("Check") With .Editor .EditType = exontrol.EXG2ANTTLib.EditTypeEnum.CheckValueType .set_Option(exontrol.EXG2ANTTLib.EditorOptionEnum.exCheckValue2,1) End With .DisplayFilterButton = True .DisplayFilterPattern = False .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exCheck End With With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") h = .AddItem("Item B") .set_CellState(.InsertItem(h,Nothing,"Sub-Item B1"),1,1) .InsertItem(h,Nothing,"Sub-Item B2") .set_ExpandItem(h,True) .AddItem("Item C") End With .FilterInclude = exontrol.EXG2ANTTLib.FilterIncludeEnum.exItemsWithChilds .FilterBarFont = .Font .FilterBarCaption = "`<fgcolor=0000FF><i>value/current</i></fgcolor>: <fgcolor=808080>` + value + `</fgcolor>` + `<br><fgcolor=0000FF><i>available</" & _ "i></fgcolor>: ` + available + `<br><fgcolor=0000FF><i>allui</i></fgcolor>: ` + allui + `<br><fgcolor=0000FF><i>all</i></fgcolor>" & _ ": ` + all + `<br><fgcolor=0000FF><i>itemcount</i></fgcolor>: <fgcolor=808080>` + itemcount + `</fgcolor>`+ `<br><fgcolor=0000FF>" & _ "<i>visibleitemcount</i></fgcolor>: <fgcolor=808080>` + visibleitemcount + `</fgcolor>`+ `<br><fgcolor=0000FF><i>matchitemcount</" & _ "i></fgcolor>: <fgcolor=808080>` + matchitemcount + `</fgcolor>`+ `<br><fgcolor=0000FF><i>promptpattern</i></fgcolor>: <fgcolor=8" & _ "08080>` + promptpattern + `</fgcolor>`+ `<br><fgcolor=0000FF><i>leafitemcount</i></fgcolor>: <fgcolor=808080>` + leafitemcount +" & _ " `</fgcolor>`" .FilterBarPromptPattern = "B" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCaptionVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .ApplyFilter() .EndUpdate() End With |
2004 |
I am using filter prompt feature, and also column's filter, just wondering if possible to compact displaying the filter bar so it won't show on multiple lines
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Columns.Add("Item").DisplayFilterButton = True With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarFont = .Font .FilterBarCaption = "`<r><i><fgcolor=808080><upline><solidline><sha ;;0>` + value" .FilterBarPromptPattern = "B" .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarCompact Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarSingleLine Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarVisible Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible With .Columns.Item(0) .FilterType = exontrol.EXG2ANTTLib.FilterTypeEnum.exFilter .Filter = "Item A|Item B" End With .ApplyFilter() .EndUpdate() End With |
2003 |
Just wondering if it is possible to show the filter bar's close button on the right ( sample 2 )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .Columns.Add("Item").DisplayFilterButton = True With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarShowCloseOnRight Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarToggle Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible .FilterBarPrompt = .FormatABC("`<r>` + value",.FilterBarPrompt) .EndUpdate() End With |
2002 |
Just wondering if it is possible to show the filter bar's close button on the right ( sample 1 )
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With .RightToLeft = True .Columns.Add("Item").DisplayFilterButton = True With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarToggle Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible .EndUpdate() End With |
2001 |
How can I change the visual appearance of the filter bar's close button (EBN)
' AddItem event - Occurs after a new Item has been inserted to Items collection. Private Sub Exg2antt1_AddItem(ByVal sender As System.Object,ByVal Item As Integer) Handles Exg2antt1.AddItem With Exg2antt1 .Items.AddBar(Item,"Task",#12/4/2017#,#12/14/2017#) End With End Sub With Exg2antt1 .BeginUpdate() With .Chart .LevelCount = 2 .FirstVisibleDate = #12/2/2017# .set_PaneWidth(False,256) End With With .VisualAppearance .Add(1,"gBFLBCJwBAEHhEJAAEhABHQDg6AADACAxRDgMQBQKAAzAJBIYhiG4cYCgMZhXDOCYXABCEYRXBIZQ7BKNIxjSJ5BhIAAyDSJMjSRJUEhqGCWYDleYYYAKHIMQLOg7IJ" & _ "jyI4/SJAYCydKAWhxIaZKJHCZoEDaTAADCNVAQp6MEIJVbVEI0e79OgBLp/Z7kECIJJAaRjHQdJxGLA8EhtCQhCZteK6SgMKJYXhWQYRXI1JwvMBrWrdQjiOYELQtMKm" & _ "SZNLYGG4dR5SVJbcYhSYsRRFMoyDIOXYDLKsdYqSpXIThObEGgaPqJYjsUjCMKnR7HVIURrBPC9TBPE69ZgmC6ucKPX51ShKFaBWDZcwFAS+UBuYCAILiEAQGZ1XT8OR" & _ "OicbgJgSTJRlCaZeDsHY7QGR4xkSYp3CaExZAQMgalQYAwjCAAfBANxcA2TgKAUOpDCGFhKg0RpXCwCwDHQHQHEyAIkCkOhbFOGA8A8DohBgRg9AccZcn8EpEjMLI2C2" & _ "DYxAgQgvAIUIVkoAAPBQDJlECTZ3CCYwDACQwUA8A5MCAWAWDiQi4l8aQOEgLJuBgBgDmYFAzEoIoIl0WALgKYJbBABADAAHgHg8VAMmqCQQDMXABAATYwTmNwBDATJX" & _ "AiAgjHmNQ5lgQ5QEQEQMmcWg/GwD5ylyNw2gMcJcjsBgBgOQQDDhRpVAMMwnDBFw1B0Ax8D0DxOmmJJIGQTY5hGMAwkwM4CAYLZAmAOJnAqAojiIGg6iieYkmeAYOHaK" & _ "JDCyCwjH6AoggsQpQliAJLhgaJ0CESBTnyDwjk+cg4g4P5IHIHJ+BWRRzlYWAxiOUxihsY4KjKLJRGqC44FCegkkkM58iAKAPnIWIWD8SRSFSfQnkmewUhYP4GiGKJ7G" & _ "0TIbCSUoggqUo0lAQ4LnEcBcD8Coiiif4nE+eAAn2HpOkcFJqi4T5SkyMw/kqQown8IBIBOdA+A+DJrBqVxXEqYo4lCApLhGHBnD8S4ymyfxmg+cwQkQP5egOUZIWoEA" & _ "kjIeIPBMBJBD+TBjBifwvkuc58hQJQPmFrYykkchclSApKjGOBuD+TRDFCfw3mmIxNi8FxFlOXhVC4aYDFyPgvg2YBcBcLZGCGCJ0DSLRzGSWQ/lmY5+mEP5gmMDBZRS" & _ "MRsFsOxMhMJJ/DsTpTnwaQaE+N5ojuNhdEYNI5C4TZJO1GRDmCaxnA2Yx4n8IpIjOTBQBQC5TgyYw7gUYRYikC0BYRwsDQBoB8eA6Q2hsE0BUXgywZtYCyHMKwnxSAhA" & _ "QHkIQhRrBaDsCwA4ERiB2EWAIYIXhhiVEgAEUYwwYjyASLge4FhHgRDkM8OQih0jWPkGgBBAQ") End With .Columns.Add("Item").DisplayFilterButton = True With .Columns.Add("Pos") .AllowSizing = False .AllowSort = False .Width = 32 .FormatColumn = "1 apos ``" .Position = 0 End With With .Items .AddItem("Item A") .AddItem("Item B") .AddItem("Item C") End With .FilterBarPromptVisible = exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarToggle Or exontrol.EXG2ANTTLib.FilterBarVisibleEnum.exFilterBarPromptVisible .set_Background32(exontrol.EXG2ANTTLib.BackgroundPartEnum.exFooterFilterBarButton,&H1000000) .EndUpdate() End With |